From 96e718a5c3a415a6bfe755ab5d98c724f1decca5 Mon Sep 17 00:00:00 2001 From: Mikael Nordfeldth Date: Sat, 3 Oct 2015 16:52:35 +0200 Subject: [PATCH] Disable qvitter-delete-notice if ActivityModeration plugin exists --- QvitterPlugin.php | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/QvitterPlugin.php b/QvitterPlugin.php index 677b50e..87db9e9 100644 --- a/QvitterPlugin.php +++ b/QvitterPlugin.php @@ -572,7 +572,7 @@ class QvitterPlugin extends Plugin { $twitter_status['is_activity'] = false; } - if($notice->verb == 'qvitter-delete-notice') { + if(ActivityUtils::compareTypes($notice->verb, array('qvitter-delete-notice', 'delete'))) { $twitter_status['qvitter_delete_notice'] = true; } @@ -797,7 +797,7 @@ class QvitterPlugin extends Plugin { $user_is_deleted = true; } - if(!$user_is_deleted) { + if(!$user_is_deleted && class_exists('StatusNet') && !array_key_exists('ActivityModeration', StatusNet::getActivePlugins())) { $rendered = sprintf(_m('%2$s deleted notice {{%4$s}}.'), htmlspecialchars($profile->getUrl()), htmlspecialchars($profile->getBestName()), @@ -835,7 +835,7 @@ class QvitterPlugin extends Plugin { public function onEndHandleFeedEntry($activity) { - if($activity->verb == 'qvitter-delete-notice') { + if($activity->verb == 'qvitter-delete-notice' && class_exists('StatusNet') && !array_key_exists('ActivityModeration', StatusNet::getActivePlugins())) { $deleter_profile_uri = $activity->actor->id; $deleted_notice_uri = $activity->objects[0]->objects[0]->content;