fix
This commit is contained in:
@ -3,6 +3,7 @@ import {createNotification} from '../utils/noticeUtils.js'
|
|||||||
import { lastView, navigateTo } from '../index.js';
|
import { lastView, navigateTo } from '../index.js';
|
||||||
import ProfilePageView from '../views/ProfilePageView.js';
|
import ProfilePageView from '../views/ProfilePageView.js';
|
||||||
import Search from '../views/Search.js';
|
import Search from '../views/Search.js';
|
||||||
|
import { sleep } from '../utils/sleep.js';
|
||||||
|
|
||||||
export default class Notice {
|
export default class Notice {
|
||||||
|
|
||||||
@ -48,11 +49,9 @@ export default class Notice {
|
|||||||
|
|
||||||
stop() {
|
stop() {
|
||||||
if (this._socket) {
|
if (this._socket) {
|
||||||
try{
|
while (this._socket.OPEN)
|
||||||
this._socket.close();
|
sleep(100);
|
||||||
}
|
this._socket.close()
|
||||||
catch (e)
|
|
||||||
{}
|
|
||||||
this._socket = undefined;
|
this._socket = undefined;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
Reference in New Issue
Block a user