HHH-6496 - Changed line 200 returning real object instead of proxy

This commit is contained in:
Kamyar Sajjadi 2012-12-17 15:49:02 +01:00 committed by Brett Meyer
parent d3867e9c1b
commit a0bbf0d029
1 changed files with 1 additions and 1 deletions

View File

@ -197,7 +197,7 @@ public class JavassistLazyInitializer extends BasicLazyInitializer implements Me
}
returnValue = thisMethod.invoke( target, args );
}
return returnValue == target ? proxy : returnValue;
return returnValue == target && returnValue.getClass().isInstance(proxy) ? proxy : returnValue;
}
catch ( InvocationTargetException ite ) {
throw ite.getTargetException();