diff --git a/modules/common/src/main/java/org/dcache/auth/OpScopedPrincipal.java b/modules/common/src/main/java/org/dcache/auth/OpScopedPrincipal.java index a4a1050012c..aa22341aa2f 100644 --- a/modules/common/src/main/java/org/dcache/auth/OpScopedPrincipal.java +++ b/modules/common/src/main/java/org/dcache/auth/OpScopedPrincipal.java @@ -49,6 +49,9 @@ public boolean equals(Object other) { return true; } + if (other == null) { + return false; + } return this.getClass().equals(other.getClass()) && ((Principal) other).getName().equals(name); }