X-Git-Url: https://git.openstreetmap.org./nominatim.git/blobdiff_plain/0df8a4e24f6129d3c2389d7cfc3f0515efb2f6f4..71b3aa9cca3f9a3fd6a5f8e0e51c0b99463d7e66:/utils/setup.php?ds=inline diff --git a/utils/setup.php b/utils/setup.php index 07b929a1..eff7b71b 100755 --- a/utils/setup.php +++ b/utils/setup.php @@ -134,7 +134,7 @@ pgsqlRunScriptFile(CONST_Path_Postgresql_Postgis.'/postgis.sql'); pgsqlRunScriptFile(CONST_Path_Postgresql_Postgis.'/spatial_ref_sys.sql'); } else { - pgsqlRunScript('CREATE EXTENSION postgis'); + pgsqlRunScript('CREATE EXTENSION IF NOT EXISTS postgis'); } if ($fPostgisVersion < 2.1) { // Function was renamed in 2.1 and throws an annoying deprecation warning @@ -730,7 +730,7 @@ } } - if (isset($aCMDResult['drop'])) + if ($aCMDResult['drop']) { // The implementation is potentially a bit dangerous because it uses // a positive selection of tables to keep, and deletes everything else.