Error response enhancements, CoreID auth client backend
This commit is contained in:
@@ -26,8 +26,8 @@ export class AuthRequiredMiddleware extends Middleware {
|
||||
if ( !this.security.hasUser() ) {
|
||||
this.session.set('@extollo:auth.intention', this.request.url)
|
||||
|
||||
if ( this.routing.hasNamedRoute('@auth.login') ) {
|
||||
return redirect(this.routing.getNamedPath('@auth.login').toRemote)
|
||||
if ( this.routing.hasNamedRoute('@auth:login') ) {
|
||||
return redirect(this.routing.getNamedPath('@auth:login').toRemote)
|
||||
} else {
|
||||
return error(new NotAuthorizedError(), HTTPStatus.FORBIDDEN)
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user