From 943b2bea09b484bd4709b6d2c4a3560ce82a2467 Mon Sep 17 00:00:00 2001 From: Evan Prodromou Date: Fri, 23 Oct 2009 11:46:44 -0400 Subject: [PATCH] update location while registering --- classes/User.php | 9 +++++++++ 1 file changed, 9 insertions(+) diff --git a/classes/User.php b/classes/User.php index 0a70c98014..b300c9edb6 100644 --- a/classes/User.php +++ b/classes/User.php @@ -198,6 +198,15 @@ class User extends Memcached_DataObject } if (!empty($location)) { $profile->location = $location; + + $loc = Location::fromName($location); + + if (!empty($loc)) { + $profile->lat = $loc->lat; + $profile->lon = $loc->lon; + $profile->location_id = $loc->location_id; + $profile->location_ns = $loc->location_ns; + } } $profile->created = common_sql_now(); -- 2.39.5