Polish: lamdbas containing only one statement should not nest this statement in a block
This commit is contained in:
committed by
Juergen Hoeller
parent
99662bc702
commit
7826567df6
@@ -347,9 +347,7 @@ public abstract class CacheAspectSupport extends AbstractCacheInvoker
|
||||
Object key = generateKey(context, CacheOperationExpressionEvaluator.NO_RESULT);
|
||||
Cache cache = context.getCaches().iterator().next();
|
||||
try {
|
||||
return wrapCacheValue(method, cache.get(key, () -> {
|
||||
return unwrapReturnValue(invokeOperation(invoker));
|
||||
}));
|
||||
return wrapCacheValue(method, cache.get(key, () -> unwrapReturnValue(invokeOperation(invoker))));
|
||||
}
|
||||
catch (Cache.ValueRetrievalException ex) {
|
||||
// The invoker wraps any Throwable in a ThrowableWrapper instance so we
|
||||
|
||||
Reference in New Issue
Block a user