This commit is contained in:
Peter Maquiran
2022-05-09 15:01:23 +01:00
parent 578e9eab35
commit 25fec510d9
3 changed files with 31 additions and 35 deletions
+6 -4
View File
@@ -116,17 +116,19 @@ export class LoginPage implements OnInit {
loader.remove()
// login to API successfully
console.log(attempt,'!!::!!');
if (attempt) {
if (attempt.UserId == SessionStore.user.UserId) {
await this.authService.SetSession(attempt, this.userattempt);
if(attempt.ChatData){
if(attempt.ChatData) {
await this.authService.loginChat(attempt.ChatData.data);
//try {
await this.authService.loginToChatWs();
// } catch(e) {}
// } catch(e) {}
}
@@ -148,7 +150,7 @@ export class LoginPage implements OnInit {
this.changeProfileService.run();
if(attempt.ChatData){
if(attempt.ChatData) {
await this.authService.loginChat(attempt.ChatData.data);
await this.authService.loginToChatWs();
}