From: Mikael Nordfeldth Date: Sat, 24 Jan 2015 11:47:39 +0000 (+0100) Subject: Added Magicsig onProfileDeleteRelated X-Git-Url: https://git.mxchange.org/?a=commitdiff_plain;h=2d0155a50f586d642f046b7053e2907ee9045e37;p=quix0rs-gnu-social.git Added Magicsig onProfileDeleteRelated --- diff --git a/plugins/OStatus/OStatusPlugin.php b/plugins/OStatus/OStatusPlugin.php index 46c49c5f55..478a4281c5 100644 --- a/plugins/OStatus/OStatusPlugin.php +++ b/plugins/OStatus/OStatusPlugin.php @@ -1356,6 +1356,12 @@ class OStatusPlugin extends Plugin { // Ostatus_profile has a 'profile_id' property, which will be used to find the object $related[] = 'Ostatus_profile'; + + // Magicsig has a "user_id" column instead, so we have to delete it more manually: + $magicsig = Magicsig::getKV('user_id', $profile->id); + if ($magicsig instanceof Magicsig) { + $magicsig->delete(); + } return true; } }