Fix too much checks for messages
This commit is contained in:
parent
887f298bd8
commit
9248f264f1
1 changed files with 5 additions and 0 deletions
|
@ -249,8 +249,13 @@ export class OsmConnection {
|
|||
});
|
||||
}
|
||||
|
||||
private isChecking = false;
|
||||
private CheckForMessagesContinuously(){
|
||||
const self =this;
|
||||
if(this.isChecking){
|
||||
return;
|
||||
}
|
||||
this.isChecking = true;
|
||||
UIEventSource.Chronic(5 * 60 * 1000).addCallback(_ => {
|
||||
if (self.isLoggedIn .data) {
|
||||
console.log("Checking for messages")
|
||||
|
|
Loading…
Reference in a new issue