fix NPE
This commit is contained in:
1 parent
3e68cc601a
commit
4dc4c56921
1 file changed
+4
@@ -154,6 +154,10 @@ public class AdminService {
|
||||
if (realm == null)
|
||||
throw new NotFoundException();
|
||||
Auth auth = authManager.authenticateCookie(realm, headers);
|
||||
if (auth == null) {
|
||||
logger.debug("No auth cookie");
|
||||
return Response.status(401).build();
|
||||
}
|
||||
UserModel user = auth.getUser();
|
||||
if (user == null) {
|
||||
return Response.status(401).build();
|
||||
|
||||
Reference in new issue
Block a user