HHH-12328 - ByteBuddyInterceptor#intercept should not wrap Exception types

This commit is contained in:
Vlad Mihalcea 2018-02-28 13:20:51 +02:00
parent af6a69645c
commit 0fc4294fed
1 changed files with 1 additions and 1 deletions

View File

@ -52,7 +52,7 @@ public class ByteBuddyInterceptor extends BasicLazyInitializer implements ProxyC
result = this.invoke( thisMethod, args, proxy );
}
catch (Throwable t) {
throw new Exception( t.getCause() );
throw t instanceof RuntimeException ? t : new Exception( t.getCause() );
}
if ( result == INVOKE_IMPLEMENTATION ) {
Object target = getImplementation();