Fixes a bug due to r1797222. I missed in some cases the EntityListIterator
might not exist in the context (this seems still weird to me, but obviously
there are cases...)
@@ -44,7 +44,9 @@ public class PerformFindTests extends OFBizTestCase {
private List<GenericValue> getCompleteList(Map<String, Object> context) {
List<GenericValue> foundElements = new LinkedList<GenericValue>();
try (EntityListIterator listIt = (EntityListIterator) context.get("listIt")) {
+ if (listIt != null) {
foundElements = listIt.getCompleteList();
+ }
} catch (GenericEntityException e) {
Debug.logError(" Failed to extract values from EntityListIterator after a performFind service", module);
}
