Refresh token done

This commit is contained in:
Eudes Inácio
2022-06-10 09:42:41 +01:00
parent 1bdf3daf12
commit 4275d71a43
16 changed files with 19 additions and 93 deletions
@@ -155,6 +155,7 @@ export class MessagesPage implements OnInit, OnChanges, AfterViewInit, OnDestroy
}
ngOnInit() {
this.chatService.refreshtoken();
this.scrollToBottom();
this.getChatMembers();
@@ -525,12 +526,6 @@ export class MessagesPage implements OnInit, OnChanges, AfterViewInit, OnDestroy
this.members = res['members'];
this.dmUsers = res['members'].filter(data => data.username != this.sessionStore.user.UserName)
this.showLoader = false;
},(error: HttpErrorResponse) => {
if(error.status === 401){
this.chatService.refreshtoken()
this.getChatMembers();
}
});
}