IDEMPIERE-5286 Fix ConcurrentModificationException in MPrintFormat.getAllItems Method (#1349)
This commit is contained in:
parent
f5a0a0a2f6
commit
935987bd9d
|
@ -300,10 +300,8 @@ public class MPrintFormat extends X_AD_PrintFormat implements ImmutablePOSupport
|
||||||
.list();
|
.list();
|
||||||
|
|
||||||
MRole role = MRole.getDefault(getCtx(), false);
|
MRole role = MRole.getDefault(getCtx(), false);
|
||||||
for (MPrintFormatItem pfi : list) {
|
list.removeIf(pfi -> !role.isColumnAccess(getAD_Table_ID(), pfi.getAD_Column_ID(), true));
|
||||||
if (! role.isColumnAccess(getAD_Table_ID(), pfi.getAD_Column_ID(), true))
|
|
||||||
list.remove(pfi);
|
|
||||||
}
|
|
||||||
MPrintFormatItem[] retValue = new MPrintFormatItem[list.size()];
|
MPrintFormatItem[] retValue = new MPrintFormatItem[list.size()];
|
||||||
list.toArray(retValue);
|
list.toArray(retValue);
|
||||||
return retValue;
|
return retValue;
|
||||||
|
|
Loading…
Reference in New Issue