Improved: Inconsistent String Comparisons, Applied plugins groovy patch from jira issue. (OFBIZ-9254)
I found an inconsistency in the code for string comparison statusId.equals("PRUN_COMPLETED") whereas it should be written as "PRUN_COMPLETED".equals(statusId) cause the former can throw NullPointerException if the variable found to be NULL.
Thanks Devanshu Vyas for your contribution.
git-svn-id: https://svn.apache.org/repos/asf/ofbiz/ofbiz-plugins/trunk@1795344 13f79535-47bb-0310-9956-ffa450edef68
This commit is contained in:
@@ -46,7 +46,7 @@ userLoginId = userLogin.partyId
|
||||
} else {
|
||||
custRequestTypeId = projectAndTaskMap.custRequestTypeId
|
||||
backlogStatusId = projectAndTaskMap.backlogStatusId
|
||||
if (custRequestTypeId.equals("RF_SCRUM_MEETINGS") && backlogStatusId.equals("CRQ_REVIEWED")) {
|
||||
if ("RF_SCRUM_MEETINGS".equals(custRequestTypeId) && "CRQ_REVIEWED".equals(backlogStatusId)) {
|
||||
projectSprintBacklogAndTaskList.add(projectAndTaskMap)
|
||||
}
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user