]> git.mxchange.org Git - quix0rs-gnu-social.git/commitdiff
Only run EndSubscribe when it is really a sub
authorMikael Nordfeldth <mmn@hethane.se>
Mon, 5 May 2014 22:22:02 +0000 (00:22 +0200)
committerMikael Nordfeldth <mmn@hethane.se>
Mon, 5 May 2014 22:22:02 +0000 (00:22 +0200)
classes/Subscription.php

index 12f4e86f10bf3009ee93a3f9af0bbf6dfcecf1ae..56df0b88be54e55d99e01afa8eeec33d83701e86 100644 (file)
@@ -124,7 +124,9 @@ class Subscription extends Managed_DataObject
                 }
             }
 
-            Event::handle('EndSubscribe', array($subscriber, $other));
+            if ($sub instanceof Subscription) { // i.e. not SubscriptionQueue
+                Event::handle('EndSubscribe', array($subscriber, $other));
+            }
         }
 
         return $sub;