decode_json() always create arrays instead of objects

This commit is contained in:
Sarah Hoffmann
2022-07-09 09:10:21 +02:00
parent 300612c5a8
commit 7cafec0750
9 changed files with 10 additions and 10 deletions

View File

@@ -445,7 +445,7 @@ class PlaceLookup
if ($this->bExtraTags) {
if ($aPlace['extra']) {
$aPlace['sExtraTags'] = json_decode($aPlace['extra']);
$aPlace['sExtraTags'] = json_decode($aPlace['extra'], true);
} else {
$aPlace['sExtraTags'] = (object) array();
}
@@ -482,7 +482,7 @@ class PlaceLookup
return (object) array();
}
$aFullNames = json_decode($sNames);
$aFullNames = json_decode($sNames, true);
$aNames = array();
foreach ($aFullNames as $sKey => $sValue) {