mirror of
https://github.com/DSpace/dspace-angular.git
synced 2025-10-15 22:13:02 +00:00
added refresh token when check on authorization cookie is successful
This commit is contained in:
@@ -208,7 +208,9 @@ export class AuthService {
|
||||
const options: HttpOptions = Object.create({});
|
||||
let headers = new HttpHeaders();
|
||||
headers = headers.append('Accept', 'application/json');
|
||||
headers = headers.append('Authorization', `Bearer ${token.accessToken}`);
|
||||
if (token && token.accessToken) {
|
||||
headers = headers.append('Authorization', `Bearer ${token.accessToken}`);
|
||||
}
|
||||
options.headers = headers;
|
||||
return this.authRequestService.postToEndpoint('login', {}, options).pipe(
|
||||
map((status: AuthStatus) => {
|
||||
|
Reference in New Issue
Block a user