]> git.mxchange.org Git - quix0rs-gnu-social.git/commitdiff
emit fewer notices for group joins
authorEvan Prodromou <evan@status.net>
Tue, 23 Aug 2011 15:49:45 +0000 (11:49 -0400)
committerEvan Prodromou <evan@status.net>
Tue, 23 Aug 2011 15:49:45 +0000 (11:49 -0400)
classes/User_group.php

index 8d08efb5ff68a183f869b16fff91962b92f53c5d..4870e39a15a768399d201c22fb188ee4e818411f 100644 (file)
@@ -529,6 +529,18 @@ class User_group extends Managed_DataObject
         // MAGICALLY put fields into current scope
         // @fixme kill extract(); it makes debugging absurdly hard
 
+               $defaults = array('nickname' => null,
+                                                 'fullname' => null,
+                                                 'homepage' => null,
+                                                 'description' => null,
+                                                 'location' => null,
+                                                 'uri' => null,
+                                                 'mainpage' => null,
+                                                 'aliases' => array(),
+                                                 'userid' => null);
+               
+               $fields = array_merge($defaults, $fields);
+               
         extract($fields);
 
         $group = new User_group();