php: force use of global Exception class

This commit is contained in:
Sarah Hoffmann
2021-07-25 16:29:04 +02:00
parent d48793c22c
commit fdff579188
4 changed files with 11 additions and 11 deletions

View File

@@ -83,7 +83,7 @@ if ($sOsmType && $iOsmId > 0) {
}
if ($sPlaceId === false) {
throw new Exception('No place with that OSM ID found.', 404);
throw new \Exception('No place with that OSM ID found.', 404);
}
} else {
if ($sPlaceId === false) {
@@ -146,7 +146,7 @@ $sSQL .= " WHERE place_id = $iPlaceID";
$aPointDetails = $oDB->getRow($sSQL, null, 'Could not get details of place object.');
if (!$aPointDetails) {
throw new Exception('No place with that place ID found.', 404);
throw new \Exception('No place with that place ID found.', 404);
}
$aPointDetails['localname'] = $aPointDetails['localname']?$aPointDetails['localname']:$aPointDetails['housenumber'];