]> git.mxchange.org Git - quix0rs-gnu-social.git/commitdiff
restructuring of User::registerNew() lost password munging
authorEvan Prodromou <evan@status.net>
Mon, 1 Feb 2010 05:47:50 +0000 (00:47 -0500)
committerEvan Prodromou <evan@status.net>
Mon, 1 Feb 2010 05:47:50 +0000 (00:47 -0500)
classes/User.php

index 4013fbc832d4388ac33a51b06c5ba09d7970d24b..0ab816b57ee301f730f4c31f18a53e9572c14fe5 100644 (file)
@@ -250,10 +250,6 @@ class User extends Memcached_DataObject
 
         $user->nickname = $nickname;
 
-        if (!empty($password)) { // may not have a password for OpenID users
-            $user->password = common_munge_password($password, $id);
-        }
-
         // Users who respond to invite email have proven their ownership of that address
 
         if (!empty($code)) {
@@ -286,6 +282,9 @@ class User extends Memcached_DataObject
 
             $user->id = $id;
             $user->uri = common_user_uri($user);
+            if (!empty($password)) { // may not have a password for OpenID users
+                $user->password = common_munge_password($password, $id);
+            }
 
             $result = $user->insert();