Fix for issue with order processing when given value is not array or Doctrine Collection