Skip to content

Commit 5d5cb9d

Browse files
committed
Always return a string. Even if array was empty.
1 parent adb30ab commit 5d5cb9d

File tree

1 file changed

+5
-1
lines changed

1 file changed

+5
-1
lines changed

app/code/Magento/Customer/Model/Address/AbstractAddress.php

Lines changed: 5 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -308,7 +308,11 @@ protected function _implodeArrayField(array $data)
308308
*/
309309
protected function _implodeArrayValues($value)
310310
{
311-
if (is_array($value) && count($value)) {
311+
if (is_array($value)) {
312+
if (!count($value)) {
313+
return '';
314+
}
315+
312316
$isScalar = false;
313317
foreach ($value as $val) {
314318
if (is_scalar($val)) {

0 commit comments

Comments
 (0)