]> git.mxchange.org Git - quix0rs-gnu-social.git/blobdiff - classes/Group_join_queue.php
Return dynamically generated URLs for thumbnails for all locally stored entries
[quix0rs-gnu-social.git] / classes / Group_join_queue.php
index 7df71ed0420cf12f824700928b947c2dd03e0b70..9ff221c49fcf4b00daff2bed97921253b9185133 100644 (file)
@@ -14,14 +14,6 @@ class Group_join_queue extends Managed_DataObject
     public $group_id;
     public $created;
 
-    /* Static get */
-    function staticGet($k,$v=null)
-    { return Memcached_DataObject::staticGet('Group_join_queue',$k,$v); }
-
-    /* Pkey get */
-    function pkeyGet($k)
-    { return Memcached_DataObject::pkeyGet('Group_join_queue',$k); }
-
     /* the code above is auto generated do not remove the tag below */
     ###END_AUTOCODE
 
@@ -58,7 +50,7 @@ class Group_join_queue extends Managed_DataObject
 
     function getMember()
     {
-        $member = Profile::staticGet('id', $this->profile_id);
+        $member = Profile::getKV('id', $this->profile_id);
 
         if (empty($member)) {
             // TRANS: Exception thrown providing an invalid profile ID.
@@ -71,7 +63,7 @@ class Group_join_queue extends Managed_DataObject
 
     function getGroup()
     {
-        $group  = User_group::staticGet('id', $this->group_id);
+        $group  = User_group::getKV('id', $this->group_id);
 
         if (empty($group)) {
             // TRANS: Exception thrown providing an invalid group ID.
@@ -84,18 +76,15 @@ class Group_join_queue extends Managed_DataObject
 
     /**
      * Abort the pending group join...
-     *
-     * @param User_group $group
      */
     function abort()
     {
         $profile = $this->getMember();
         $group = $this->getGroup();
-        if ($request) {
-            if (Event::handle('StartCancelJoinGroup', array($profile, $group))) {
-                $this->delete();
-                Event::handle('EndCancelJoinGroup', array($profile, $group));
-            }
+
+        if (Event::handle('StartCancelJoinGroup', array($profile, $group))) {
+            $this->delete();
+            Event::handle('EndCancelJoinGroup', array($profile, $group));
         }
     }
 
@@ -127,8 +116,8 @@ class Group_join_queue extends Managed_DataObject
      */
     public function notify()
     {
-        $joiner = Profile::staticGet('id', $this->profile_id);
-        $group = User_group::staticGet('id', $this->group_id);
+        $joiner = Profile::getKV('id', $this->profile_id);
+        $group = User_group::getKV('id', $this->group_id);
         mail_notify_group_join_pending($group, $joiner);
     }
 }