Skip to content

Commit

Permalink
feat: add err catch
Browse files Browse the repository at this point in the history
  • Loading branch information
kungfuboy committed Sep 9, 2022
1 parent eedb8ba commit b82f05a
Showing 1 changed file with 6 additions and 1 deletion.
Original file line number Diff line number Diff line change
Expand Up @@ -89,8 +89,13 @@ export class WebsocketComponent implements OnInit, OnDestroy {
console.log('connect_error', error);
this.isSocketConnect = false;
});
this.socket.on('error', (error) => {
// * conncet socketIO is failed
console.log('error', error);
this.isSocketConnect = false;
});
} catch (e) {
console.log('connect not allow', e);
console.log('Connect not allow', e);
this.isSocketConnect = false;
}
}
Expand Down

0 comments on commit b82f05a

Please sign in to comment.