X-Git-Url: http://git.argeo.org/?a=blobdiff_plain;f=org.argeo.cms%2Fsrc%2Forg%2Fargeo%2Fcms%2Fauth%2FCurrentUser.java;h=5b4ab174e59be0d57a2ce986e78d94fc643c7b7f;hb=18af628c072e386420f03261ab207a72341a0a1b;hp=33a226737bd5c8ac52c6ea3febfacd5b55340f0a;hpb=a24df5e9ef0900033b0e431a819432101bdb1fc4;p=lgpl%2Fargeo-commons.git diff --git a/org.argeo.cms/src/org/argeo/cms/auth/CurrentUser.java b/org.argeo.cms/src/org/argeo/cms/auth/CurrentUser.java index 33a226737..5b4ab174e 100644 --- a/org.argeo.cms/src/org/argeo/cms/auth/CurrentUser.java +++ b/org.argeo.cms/src/org/argeo/cms/auth/CurrentUser.java @@ -65,15 +65,6 @@ public final class CurrentUser { return isAnonymous(currentSubject()); } - /** - * Whether a user is currently authenticated. @deprecate User !isAnonymous() - * instead. - */ - @Deprecated - public static boolean isRegistered() { - return !isAnonymous(); - } - /** Roles of the currently logged-in user */ public final static Set roles() { return roles(currentSubject()); @@ -91,7 +82,7 @@ public final class CurrentUser { } /** Executes as the current user */ - public final static T doAs(PrivilegedExceptionAction action) throws PrivilegedActionException { + public final static T tryAs(PrivilegedExceptionAction action) throws PrivilegedActionException { return Subject.doAs(currentSubject(), action); }