Small performance improvement on Payment completion - don't rewrite a valid value (avoid save/check cycle)
This commit is contained in:
parent
20fa496489
commit
2f9d6e74e6
|
@ -411,8 +411,10 @@ public class MPeriod extends X_C_Period
|
||||||
// We are OK
|
// We are OK
|
||||||
if (isInPeriod(today))
|
if (isInPeriod(today))
|
||||||
{
|
{
|
||||||
as.setC_Period_ID(getC_Period_ID());
|
if (as.getC_Period_ID() != getC_Period_ID()) {
|
||||||
as.save();
|
as.setC_Period_ID(getC_Period_ID());
|
||||||
|
as.save();
|
||||||
|
}
|
||||||
}
|
}
|
||||||
return true;
|
return true;
|
||||||
}
|
}
|
||||||
|
|
Loading…
Reference in New Issue