Skip to content

Commit 8befca4

Browse files
mawen12mp911de
authored andcommitted
Remove redundant code in DefaultEntityCallbacks#callback.
Original pull request: #3053 Closes #3055
1 parent 43caf49 commit 8befca4

File tree

1 file changed

+1
-2
lines changed

1 file changed

+1
-2
lines changed

src/main/java/org/springframework/data/mapping/callback/DefaultEntityCallbacks.java

+1-2
Original file line numberDiff line numberDiff line change
@@ -67,8 +67,7 @@ public <T> T callback(Class<? extends EntityCallback> callbackType, T entity, Ob
6767

6868
Assert.notNull(entity, "Entity must not be null");
6969

70-
Class<T> entityType = (Class<T>) (entity != null ? ClassUtils.getUserClass(entity.getClass())
71-
: callbackDiscoverer.resolveDeclaredEntityType(callbackType).getRawClass());
70+
Class<T> entityType = (Class<T>) ClassUtils.getUserClass(entity.getClass());
7271

7372
Method callbackMethod = callbackMethodCache.computeIfAbsent(callbackType, it -> {
7473

0 commit comments

Comments
 (0)