Check for an array (for PHP7.2 support)

This commit is contained in:
snipe 2018-03-03 17:07:07 -08:00
parent 68a9855506
commit 123e317e52

View file

@ -690,7 +690,7 @@ class Helper
$array['status'] = $status;
$array['messages'] = $messages;
if (($messages) && (count($messages) > 0)) {
if (($messages) && (is_array($messages)) && (count($messages) > 0)) {
$array['messages'] = $messages;
}
($payload) ? $array['payload'] = $payload : $array['payload'] = null;