mirror of
https://github.com/DSpace/dspace-angular.git
synced 2025-10-07 01:54:15 +00:00
[DSC-287] Fixed for yarn start error 500 loading
This commit is contained in:
@@ -1,6 +1,5 @@
|
|||||||
import { ServerResponseService } from '../core/services/server-response.service';
|
import { ServerResponseService } from '../core/services/server-response.service';
|
||||||
import { Component, ChangeDetectionStrategy, OnInit } from '@angular/core';
|
import { Component, ChangeDetectionStrategy, OnInit } from '@angular/core';
|
||||||
import { AuthService } from '../core/auth/auth.service';
|
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* This component representing the `PageNotFound` DSpace page.
|
* This component representing the `PageNotFound` DSpace page.
|
||||||
@@ -11,23 +10,5 @@ import { AuthService } from '../core/auth/auth.service';
|
|||||||
templateUrl: './page-internal-server-error.component.html',
|
templateUrl: './page-internal-server-error.component.html',
|
||||||
changeDetection: ChangeDetectionStrategy.Default
|
changeDetection: ChangeDetectionStrategy.Default
|
||||||
})
|
})
|
||||||
export class PageInternalServerErrorComponent implements OnInit {
|
export class PageInternalServerErrorComponent {
|
||||||
|
|
||||||
/**
|
|
||||||
* Initialize instance variables
|
|
||||||
*
|
|
||||||
* @param {AuthService} authservice
|
|
||||||
* @param {ServerResponseService} responseService
|
|
||||||
*/
|
|
||||||
constructor(private authservice: AuthService, private responseService: ServerResponseService) {
|
|
||||||
this.responseService.setNotFound();
|
|
||||||
}
|
|
||||||
|
|
||||||
/**
|
|
||||||
* Remove redirect url from the state
|
|
||||||
*/
|
|
||||||
ngOnInit(): void {
|
|
||||||
this.authservice.clearRedirectUrl();
|
|
||||||
}
|
|
||||||
|
|
||||||
}
|
}
|
||||||
|
@@ -71,5 +71,9 @@ export class RootComponent implements OnInit {
|
|||||||
.pipe(
|
.pipe(
|
||||||
map(([collapsed, mobile]) => collapsed || mobile)
|
map(([collapsed, mobile]) => collapsed || mobile)
|
||||||
);
|
);
|
||||||
|
|
||||||
|
if (this.router.url === '/500') {
|
||||||
|
this.shouldShowRouteLoader = false;
|
||||||
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
Reference in New Issue
Block a user