X-Git-Url: https://git.openstreetmap.org./nominatim.git/blobdiff_plain/143ff1446656ee995356c7a7b5eaa624140c70d8..3734f1d0b84c642ba89b5a4c39bac845f5627be7:/lib-php/TokenList.php?ds=sidebyside diff --git a/lib-php/TokenList.php b/lib-php/TokenList.php index bc8f9c3f..9a3950a1 100644 --- a/lib-php/TokenList.php +++ b/lib-php/TokenList.php @@ -1,4 +1,12 @@ aTokens as $aTokenList) { foreach ($aTokenList as $oToken) { if (is_a($oToken, '\Nominatim\Token\Word')) { - $ids[$oToken->iId] = $oToken->iId; + $ids[$oToken->getId()] = $oToken->getId(); } } } @@ -109,9 +117,9 @@ class TokenList $aWordsIDs = array(); foreach ($this->aTokens as $sToken => $aWords) { foreach ($aWords as $aToken) { - if ($aToken->iId !== null) { - $aWordsIDs[$aToken->iId] = - '#'.$sToken.'('.$aToken->iId.')#'; + $iId = $aToken->getId(); + if ($iId !== null) { + $aWordsIDs[$iId] = '#'.$sToken.'('.$aToken->debugCode().' '.$iId.')#'; } } }