DATACMNS-410 - Fixed bug in ReflectionRepositoryInvoker#invokeFindOne.
We now delegate calls to invokeFindOne to the correct target repository. Original pull request: #80.
This commit is contained in:
committed by
Oliver Gierke
parent
11f1207e4e
commit
f148d19c81
@@ -29,6 +29,7 @@ import org.springframework.util.ReflectionUtils;
|
||||
* information.
|
||||
*
|
||||
* @author Oliver Gierke
|
||||
* @author Thomas Darimont
|
||||
* @since 1.6
|
||||
*/
|
||||
class ReflectionRepositoryInvoker<T> implements CrudInvoker<T> {
|
||||
@@ -72,6 +73,6 @@ class ReflectionRepositoryInvoker<T> implements CrudInvoker<T> {
|
||||
@Override
|
||||
@SuppressWarnings("unchecked")
|
||||
public T invokeFindOne(Serializable id) {
|
||||
return (T) ReflectionUtils.invokeMethod(methods.getFindOneMethod(), id);
|
||||
return (T) ReflectionUtils.invokeMethod(methods.getFindOneMethod(), repository, id);
|
||||
}
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user