summaryrefslogtreecommitdiff
path: root/plugins/Facebook/facebookremove.php
diff options
context:
space:
mode:
authorBrion Vibber <brion@pobox.com>2010-10-18 15:21:02 -0700
committerBrion Vibber <brion@pobox.com>2010-10-18 15:21:02 -0700
commit53d45d7ffbe6bcdf336a0e666942557c11cf909b (patch)
tree7c26b636624162fd1036529ecc08ae63caef59f6 /plugins/Facebook/facebookremove.php
parent9a35e48ee2a15ded31dd1dba8e0af9071e8a28ac (diff)
parent39cfdf0d8b333fec0c35e02d3ce9abb4f4338bf5 (diff)
Merge branch '0.9.x'
Diffstat (limited to 'plugins/Facebook/facebookremove.php')
-rw-r--r--plugins/Facebook/facebookremove.php6
1 files changed, 6 insertions, 0 deletions
diff --git a/plugins/Facebook/facebookremove.php b/plugins/Facebook/facebookremove.php
index b048a435f..bc76daaef 100644
--- a/plugins/Facebook/facebookremove.php
+++ b/plugins/Facebook/facebookremove.php
@@ -48,6 +48,12 @@ class FacebookremoveAction extends FacebookAction
$flink = Foreign_link::getByForeignID($this->arg('fb_sig_user'), 2);
+ if (!$flink) {
+ common_log(LOG_ERR, "Tried to delete missing foreign_link entry with Facebook ID " . $this->arg('fb_sig_user'));
+ $this->serverError(_m('Couldn\'t remove Facebook user: already deleted.'));
+ return;
+ }
+
common_debug("Removing foreign link to Facebook - local user ID: $flink->user_id, Facebook ID: $flink->foreign_id");
$result = $flink->delete();