expiry display not working
This commit is contained in:
@ -3,8 +3,6 @@ import { MessageService } from './message.service';
|
||||
import { HttpClient, HttpHeaders } from '@angular/common/http';
|
||||
import { UserCreds } from './userCreds'
|
||||
import jwt_decode from 'jwt-decode'
|
||||
import { Observable } from 'rxjs';
|
||||
import { ComplexOuterSubscriber } from 'rxjs/internal/innerSubscribe';
|
||||
|
||||
|
||||
|
||||
@ -21,6 +19,7 @@ export class TokenService {
|
||||
public static Id_AuthToken_Key : string = "id_authtoken";
|
||||
public static Id_RefreshToken_Key : string = "id_refreshtoken";
|
||||
|
||||
|
||||
constructor(private http: HttpClient, private messageService: MessageService) {
|
||||
}
|
||||
|
||||
@ -81,23 +80,4 @@ export class TokenService {
|
||||
}
|
||||
}
|
||||
|
||||
expiryUpdate() : Observable<number> {
|
||||
const exUp = new Observable<number>((observer) => {
|
||||
let i = 600
|
||||
|
||||
while (i != 0) {
|
||||
observer.next(i)
|
||||
i -= 1
|
||||
await new Promise(f => setTimeout(f, 1000))
|
||||
}
|
||||
observer.complete()
|
||||
|
||||
return {
|
||||
unsubscribe() {
|
||||
}
|
||||
}
|
||||
})
|
||||
return exUp
|
||||
}
|
||||
|
||||
}
|
||||
|
Reference in New Issue
Block a user