mirror of
https://code.equilibrium.co.ao/ITO/doneit-web.git
synced 2026-04-18 20:47:54 +00:00
save
This commit is contained in:
@@ -21,7 +21,6 @@ export class ChatService {
|
|||||||
private authService: AuthService,
|
private authService: AuthService,
|
||||||
private storageService:StorageService,) {
|
private storageService:StorageService,) {
|
||||||
this.headers = new HttpHeaders();
|
this.headers = new HttpHeaders();
|
||||||
this.storageService.get()
|
|
||||||
this.authService.userData$.subscribe((res:any)=>{
|
this.authService.userData$.subscribe((res:any)=>{
|
||||||
this.headers = this.headers.set('X-User-Id', res.userId);
|
this.headers = this.headers.set('X-User-Id', res.userId);
|
||||||
this.headers = this.headers.set('X-Auth-Token', res.authToken);
|
this.headers = this.headers.set('X-Auth-Token', res.authToken);
|
||||||
|
|||||||
@@ -13,7 +13,7 @@ import { Storage } from '@ionic/storage';
|
|||||||
}
|
}
|
||||||
|
|
||||||
// Get the value
|
// Get the value
|
||||||
async get(user: any) {
|
async get() {
|
||||||
const ret = await this.storage.get('user').then(res=>{
|
const ret = await this.storage.get('user').then(res=>{
|
||||||
return JSON.parse(unescape(atob(ret.value)));
|
return JSON.parse(unescape(atob(ret.value)));
|
||||||
});
|
});
|
||||||
|
|||||||
Reference in New Issue
Block a user