Cleanup unnecessary unboxing
Unboxing is unnecessary under Java 5 and newer, and can be safely removed.
This commit is contained in:
committed by
Josh Cummings
parent
2306d987e9
commit
2056834432
+1
-1
@@ -23,7 +23,7 @@ public final class ExpressionUtils {
|
||||
|
||||
public static boolean evaluateAsBoolean(Expression expr, EvaluationContext ctx) {
|
||||
try {
|
||||
return expr.getValue(ctx, Boolean.class).booleanValue();
|
||||
return expr.getValue(ctx, Boolean.class);
|
||||
}
|
||||
catch (EvaluationException e) {
|
||||
throw new IllegalArgumentException("Failed to evaluate expression '"
|
||||
|
||||
+2
-2
@@ -105,7 +105,7 @@ public class KeyBasedPersistenceTokenService implements TokenService, Initializi
|
||||
|
||||
long creationTime;
|
||||
try {
|
||||
creationTime = Long.decode(tokens[0]).longValue();
|
||||
creationTime = Long.decode(tokens[0]);
|
||||
}
|
||||
catch (NumberFormatException nfe) {
|
||||
throw new IllegalArgumentException("Expected number but found " + tokens[0]);
|
||||
@@ -144,7 +144,7 @@ public class KeyBasedPersistenceTokenService implements TokenService, Initializi
|
||||
}
|
||||
|
||||
private String computeServerSecretApplicableAt(long time) {
|
||||
return serverSecret + ":" + new Long(time % serverInteger.intValue()).intValue();
|
||||
return serverSecret + ":" + new Long(time % serverInteger).intValue();
|
||||
}
|
||||
|
||||
/**
|
||||
|
||||
Reference in New Issue
Block a user