mirror of
https://code.equilibrium.co.ao/ITO/doneit-web.git
synced 2026-04-18 20:47:54 +00:00
Bug session expired resolved
This commit is contained in:
@@ -10,6 +10,7 @@ import { FileLoaderService } from 'src/app/services/file/file-loader.service';
|
||||
import { FileToBase64Service } from 'src/app/services/file/file-to-base64.service';
|
||||
import { environment } from 'src/environments/environment';
|
||||
import { ThemeService } from 'src/app/services/theme.service'
|
||||
import { HttpErrorResponse } from '@angular/common/http';
|
||||
|
||||
@Component({
|
||||
selector: 'app-chat-options-features',
|
||||
@@ -117,8 +118,12 @@ export class ChatOptionsFeaturesPage implements OnInit {
|
||||
|
||||
this.chatService.sendMessage(body).subscribe(res=> {
|
||||
//
|
||||
},(error) => {
|
||||
|
||||
},(error: HttpErrorResponse) => {
|
||||
if(error.status === 401){
|
||||
this.chatService.refreshtoken()
|
||||
this.chatService.sendMessage(body);
|
||||
}
|
||||
|
||||
});
|
||||
//
|
||||
};
|
||||
@@ -144,8 +149,12 @@ export class ChatOptionsFeaturesPage implements OnInit {
|
||||
this.chatService.sendMessage(body).subscribe(res=> {
|
||||
|
||||
|
||||
},(error) => {
|
||||
|
||||
},(error: HttpErrorResponse) => {
|
||||
if(error.status === 401){
|
||||
this.chatService.refreshtoken()
|
||||
this.chatService.sendMessage(body);
|
||||
}
|
||||
|
||||
});
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user