mirror of
https://github.com/Alfresco/alfresco-community-repo.git
synced 2025-07-31 17:39:05 +00:00
Removed redundant conditional expression
This commit is contained in:
@@ -1072,7 +1072,7 @@ public class RecordsManagementAuditServiceImpl extends AbstractLifecycleBean
|
||||
NodeRef nodeRef = params.getNodeRef();
|
||||
int maxEntries = params.getMaxEntries();
|
||||
// Reverse order if the results are limited
|
||||
boolean forward = maxEntries > 0 ? false : true;
|
||||
boolean forward = maxEntries <= 0;
|
||||
|
||||
// start the audit trail report
|
||||
writeAuditTrailHeader(writer, params, reportFormat);
|
||||
|
@@ -226,7 +226,7 @@ public class RecordCategoryType extends BaseBehaviourBean
|
||||
@Override
|
||||
public boolean getMustCopy(QName classQName, CopyDetails copyDetails)
|
||||
{
|
||||
return nodeService.getType(copyDetails.getTargetParentNodeRef()).equals(TYPE_RECORD_FOLDER) ? false : true;
|
||||
return !nodeService.getType(copyDetails.getTargetParentNodeRef()).equals(TYPE_RECORD_FOLDER);
|
||||
}
|
||||
};
|
||||
}
|
||||
|
@@ -161,7 +161,7 @@ public class CustomPropertyDefinitionPut extends BaseCustomPropertyWebScript
|
||||
if (constraintRef == null)
|
||||
{
|
||||
result = rmAdminService.removeCustomPropertyDefinitionConstraints(propQName);
|
||||
updated = constraints.isEmpty() ? false : true;
|
||||
updated = !constraints.isEmpty();
|
||||
}
|
||||
else
|
||||
{
|
||||
|
@@ -533,7 +533,7 @@ public class ApiNodesModelFactory
|
||||
if (includeParam.contains(RMNode.PARAM_HAS_RETENTION_SCHEDULE))
|
||||
{
|
||||
DispositionSchedule ds = dispositionService.getDispositionSchedule(info.getNodeRef());
|
||||
recordCategoryChild.setHasRetentionSchedule(ds !=null ? true : false);
|
||||
recordCategoryChild.setHasRetentionSchedule(ds != null);
|
||||
}
|
||||
if((!isMinimalInfo && propertyFilter.isAllowed(RMNode.PARAM_IS_CLOSED)) || (isMinimalInfo && includeParam.contains(RMNode.PARAM_IS_CLOSED)))
|
||||
{
|
||||
@@ -673,7 +673,7 @@ public class ApiNodesModelFactory
|
||||
if (parameters.getInclude().contains(RMNode.PARAM_HAS_RETENTION_SCHEDULE))
|
||||
{
|
||||
DispositionSchedule ds = dispositionService.getDispositionSchedule(info.getNodeRef());
|
||||
recordCategory.setHasRetentionSchedule(ds !=null ? true : false);
|
||||
recordCategory.setHasRetentionSchedule(ds != null);
|
||||
}
|
||||
|
||||
return recordCategory;
|
||||
|
@@ -145,11 +145,11 @@ public class CustomEMailMappingServiceImplTest extends BaseRMTestCase
|
||||
|
||||
private boolean checkCustomMappingsSize(int expected)
|
||||
{
|
||||
return expected == eMailMappingService.getCustomMappings().size() ? true : false;
|
||||
return expected == eMailMappingService.getCustomMappings().size();
|
||||
}
|
||||
|
||||
private boolean checkEmailMappingKeysSize(int expected)
|
||||
{
|
||||
return expected == eMailMappingService.getEmailMappingKeys().size() ? true : false;
|
||||
return expected == eMailMappingService.getEmailMappingKeys().size();
|
||||
}
|
||||
}
|
||||
|
Reference in New Issue
Block a user