mirror of
https://github.com/hibernate/hibernate-orm
synced 2025-02-17 16:44:57 +00:00
HHH-13455 - Enabling Enhancement as a Proxy causes IllegalStateException when using Javassist
(cherry picked from commit beac4865331c9ebd9ca65b35348a81bc497d52c3)
This commit is contained in:
parent
1ff9d19d8e
commit
c211c61d86
@ -105,7 +105,10 @@ private Collection<CtField> collectInheritPersistentFields(CtClass managedCtClas
|
||||
try {
|
||||
CtClass managedCtSuperclass = managedCtClass.getSuperclass();
|
||||
|
||||
if ( !enhancementContext.isMappedSuperclassClass( managedCtSuperclass ) ) {
|
||||
if ( enhancementContext.isEntityClass( managedCtSuperclass ) ) {
|
||||
return Collections.emptyList();
|
||||
}
|
||||
else if ( !enhancementContext.isMappedSuperclassClass( managedCtSuperclass ) ) {
|
||||
return collectInheritPersistentFields( managedCtSuperclass );
|
||||
}
|
||||
log.debugf( "Found @MappedSuperclass %s to collectPersistenceFields", managedCtSuperclass.getName() );
|
||||
|
@ -24,4 +24,9 @@ public UnloadedCtField(CtField ctField) {
|
||||
public boolean hasAnnotation(Class<? extends Annotation> annotationType) {
|
||||
return ctField.hasAnnotation( annotationType );
|
||||
}
|
||||
|
||||
@Override
|
||||
public String toString() {
|
||||
return this.ctField.toString();
|
||||
}
|
||||
}
|
||||
|
Loading…
x
Reference in New Issue
Block a user