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 62cea68007
commit 18b0325e51
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();