Skip to content

Commit

Permalink
Fix dead code warning by moving null check to the correct spot
Browse files Browse the repository at this point in the history
git-svn-id: https://svn.apache.org/repos/asf/ofbiz/trunk@1631018 13f79535-47bb-0310-9956-ffa450edef68
  • Loading branch information
lektran committed Oct 11, 2014
1 parent b3008ec commit bdefc8f
Showing 1 changed file with 4 additions and 3 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -274,14 +274,15 @@ private void loadContainer() throws ContainerException{
String groupNameToUse = overrideGroup != null ? overrideGroup : entityGroupName;
Delegator delegator = DelegatorFactory.getDelegator(delegatorNameToUse);
Delegator baseDelegator = null;
if (delegator == null) {
throw new ContainerException("Invalid delegator name!");
}

if (delegator.getDelegatorTenantId() != null) {
baseDelegator = DelegatorFactory.getDelegator(delegator.getDelegatorBaseName());
} else {
baseDelegator = delegator;
}
if (delegator == null) {
throw new ContainerException("Invalid delegator name!");
}

GenericHelperInfo helperInfo = delegator.getGroupHelperInfo(groupNameToUse);
if (helperInfo == null) {
Expand Down

0 comments on commit bdefc8f

Please sign in to comment.