mirror of
https://github.com/freqtrade/frequi.git
synced 2024-11-23 03:25:15 +00:00
Reliably use setIsBotOnline
This commit is contained in:
parent
8a7c6cbddc
commit
0644a49ca8
|
@ -162,11 +162,11 @@ export function createBotSubStore(botId: string, botName: string) {
|
|||
const now = Date.now();
|
||||
// TODO: Name collision!
|
||||
this.ping = `${result.data.status} ${now.toString()}`;
|
||||
this.isBotOnline = true;
|
||||
this.setIsBotOnline(true);
|
||||
return Promise.resolve();
|
||||
} catch (error) {
|
||||
console.log('ping fail');
|
||||
this.isBotOnline = false;
|
||||
this.setIsBotOnline(false);
|
||||
return Promise.reject();
|
||||
}
|
||||
},
|
||||
|
|
Loading…
Reference in New Issue
Block a user