related to ISSUE-42816: Applied Sonarlint suggestions
authorIñigo Lerga <inigo.lerga@openbravo.com>
Tue, 14 Jan 2020 10:17:11 +0100
changeset 36957 95c3147aa768
parent 36956 8e967c22d483
child 36958 69fe71ead208
related to ISSUE 42816: Applied Sonarlint suggestions
modules/org.openbravo.advpaymentmngt/src/org/openbravo/advpaymentmngt/process/FIN_BankStatementProcess.java
--- a/modules/org.openbravo.advpaymentmngt/src/org/openbravo/advpaymentmngt/process/FIN_BankStatementProcess.java	Tue Jan 14 10:03:49 2020 +0100
+++ b/modules/org.openbravo.advpaymentmngt/src/org/openbravo/advpaymentmngt/process/FIN_BankStatementProcess.java	Tue Jan 14 10:17:11 2020 +0100
@@ -98,7 +98,7 @@
             }
           }
         }
-        if (msg.getType() != null && !msg.getType().toLowerCase().equals("warning")) {
+        if (msg.getType() != null && !msg.getType().equalsIgnoreCase("warning")) {
           // Success
           bankStatement.setProcessed(true);
           bankStatement.setAPRMProcessBankStatement("R");
@@ -205,7 +205,7 @@
       obc.addOrderBy(FIN_BankStatementLine.PROPERTY_TRANSACTIONDATE, true);
       obc.setMaxResults(1);
       final List<FIN_BankStatementLine> bst = obc.list();
-      if (bst.size() == 0) {
+      if (bst.isEmpty()) {
         return minDate;
       }
       minDate = bst.get(0).getTransactionDate();
@@ -250,7 +250,6 @@
     } finally {
       OBContext.restorePreviousMode();
     }
-    return;
   }
 
 }