HHH-14242 Micro optimisations of ActionQueue: redundant branch evaluation

This commit is contained in:
Dmitry Gusev 2020-09-17 08:09:50 +01:00 committed by Sanne Grinovero
parent 71ef49d6b1
commit 77cf9d5108
1 changed files with 2 additions and 2 deletions

View File

@ -1179,7 +1179,7 @@ public class ActionQueue {
if ( prevBatchIdentifier.hasAnyParentEntityNames( batchIdentifier ) ) {
prevBatchIdentifier.parent = batchIdentifier;
}
if ( batchIdentifier.hasAnyChildEntityNames( prevBatchIdentifier ) ) {
else if ( batchIdentifier.hasAnyChildEntityNames( prevBatchIdentifier ) ) {
prevBatchIdentifier.parent = batchIdentifier;
}
}
@ -1191,7 +1191,7 @@ public class ActionQueue {
nextBatchIdentifier.parent = batchIdentifier;
nextBatchIdentifier.getParentEntityNames().add( batchIdentifier.getEntityName() );
}
if ( batchIdentifier.hasAnyChildEntityNames( nextBatchIdentifier ) ) {
else if ( batchIdentifier.hasAnyChildEntityNames( nextBatchIdentifier ) ) {
nextBatchIdentifier.parent = batchIdentifier;
nextBatchIdentifier.getParentEntityNames().add( batchIdentifier.getEntityName() );
}