Skip to content

Commit 976a176

Browse files
Unset cache control in api response array
1 parent 4b0db9d commit 976a176

File tree

1 file changed

+4
-2
lines changed

1 file changed

+4
-2
lines changed

app/code/community/Mage42/PostcodeNL/Model/System/Config/Source/AutocompleteCountry.php

Lines changed: 4 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -12,7 +12,9 @@ public function toOptionArray($isMultiselect = false)
1212
['value' => 'error', 'label' => $response['mage42_postcodenl_message']]
1313
];
1414
}
15-
15+
16+
// Unset unexpected cache-control array property, to be able to loop through the countries
17+
unset($response['cache-control']);
1618
$result = array();
1719
foreach ($response as $country)
1820
{
@@ -24,4 +26,4 @@ public function toOptionArray($isMultiselect = false)
2426

2527
return $result;
2628
}
27-
}
29+
}

0 commit comments

Comments
 (0)