summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--classes/User.php5
1 files changed, 4 insertions, 1 deletions
diff --git a/classes/User.php b/classes/User.php
index 2c256301c..1928a3c62 100644
--- a/classes/User.php
+++ b/classes/User.php
@@ -548,7 +548,10 @@ class User extends Memcached_DataObject
return false;
}
- Subscription::cancel($other, $this->getProfile());
+ $self = $this->getProfile();
+ if (Subscription::exists($other, $self)) {
+ Subscription::cancel($other, $self);
+ }
$block->query('COMMIT');