mirror of
https://github.com/scm-manager/scm-manager.git
synced 2025-11-11 16:05:44 +01:00
Reduce SecurityFilter to user injection and enable SecurityInterceptor
Remove all the unnecessary stuff and all endpoints that would be no longer secure.
This commit is contained in:
@@ -26,7 +26,11 @@ public class ContextualExceptionMapper<E extends ExceptionWithContext> implement
|
||||
|
||||
@Override
|
||||
public Response toResponse(E exception) {
|
||||
logger.debug("map {} to status code {}", type.getSimpleName(), status.getStatusCode(), exception);
|
||||
if (logger.isTraceEnabled()) {
|
||||
logger.trace("map {} to status code {}", type.getSimpleName(), status.getStatusCode(), exception);
|
||||
} else {
|
||||
logger.debug("map {} to status code {} with message '{}'", type.getSimpleName(), status.getStatusCode(), exception.getMessage());
|
||||
}
|
||||
return Response.status(status)
|
||||
.entity(mapper.map(exception))
|
||||
.type(VndMediaType.ERROR_TYPE)
|
||||
|
||||
Reference in New Issue
Block a user