From db3c6d5bbbea425eca7c39b72d6b683258cc7de3 Mon Sep 17 00:00:00 2001 From: "tung.nv" Date: Thu, 11 Jan 2024 11:24:43 +0700 Subject: [PATCH] dev --- lib/PayPal/Common/PayPalModel.php | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/lib/PayPal/Common/PayPalModel.php b/lib/PayPal/Common/PayPalModel.php index fdfaba8d..b228320b 100644 --- a/lib/PayPal/Common/PayPalModel.php +++ b/lib/PayPal/Common/PayPalModel.php @@ -173,7 +173,7 @@ private function _convertToArray($param) foreach ($param as $k => $v) { if ($v instanceof PayPalModel) { $ret[$k] = $v->toArray(); - } else if (sizeof($v) <= 0 && is_array($v)) { + } else if (is_array($v) && sizeof($v) <= 0) { $ret[$k] = array(); } else if (is_array($v)) { $ret[$k] = $this->_convertToArray($v);