IDEMPIERE-455 Discover and fix FindBugs problems / Pattern: RCN_REDUNDANT_NULLCHECK_WOULD_HAVE_BEEN_A_NPE
This commit is contained in:
parent
75628911f2
commit
751f74cb46
|
@ -197,12 +197,12 @@ public class Doc_Production extends Doc
|
|||
fl = fact.createLine(line,
|
||||
account,
|
||||
as.getC_Currency_ID(), variance.negate());
|
||||
fl.setQty(Env.ZERO);
|
||||
if (fl == null)
|
||||
{
|
||||
p_Error = "Couldn't post variance " + line.getLine() + " - " + line;
|
||||
return null;
|
||||
}
|
||||
fl.setQty(Env.ZERO);
|
||||
}
|
||||
// costs = bomCost.negate();
|
||||
}
|
||||
|
|
|
@ -950,7 +950,7 @@ public class MWFActivity extends X_AD_WF_Activity implements Runnable
|
|||
*/
|
||||
private boolean performWork (Trx trx) throws Exception
|
||||
{
|
||||
log.info (m_node + " [" + trx.getTrxName() + "]");
|
||||
log.info (m_node + " [" + (trx!=null ? trx.getTrxName() : "") + "]");
|
||||
m_docStatus = null;
|
||||
if (m_node.getPriority() != 0) // overwrite priority if defined
|
||||
setPriority(m_node.getPriority());
|
||||
|
|
|
@ -322,9 +322,9 @@ public class WTreeMaintenance extends TreeMaintenance implements IFormController
|
|||
Treeitem ti = centerTree.getSelectedItem();
|
||||
DefaultTreeNode<?> stn = (DefaultTreeNode<?>) ti.getValue();
|
||||
MTreeNode tn = (MTreeNode)stn.getData();
|
||||
log.info(tn.toString());
|
||||
if (tn == null)
|
||||
return;
|
||||
log.info(tn.toString());
|
||||
ListModel<Object> model = centerList.getModel();
|
||||
int size = model.getSize();
|
||||
int index = -1;
|
||||
|
|
Loading…
Reference in New Issue