X-Git-Url: https://git.openstreetmap.org./nominatim.git/blobdiff_plain/7d9665d8d2251a845d97b409aaf1a758eca89439..f74dc38766ea786b0419bae8de7791b70171841d:/lib-sql/functions/placex_triggers.sql

diff --git a/lib-sql/functions/placex_triggers.sql b/lib-sql/functions/placex_triggers.sql
index 9a31f3ae..e3be9503 100644
--- a/lib-sql/functions/placex_triggers.sql
+++ b/lib-sql/functions/placex_triggers.sql
@@ -911,7 +911,7 @@ BEGIN
       -- determine postcode
       NEW.postcode := coalesce(token_normalized_postcode(NEW.address->'postcode'),
                                location.postcode,
-                               get_nearest_postcode(NEW.country_code, NEW.geometry));
+                               get_nearest_postcode(NEW.country_code, NEW.centroid));
 
       IF NEW.name is not NULL THEN
           NEW.name := add_default_place_name(NEW.country_code, NEW.name);
