]> git.mxchange.org Git - quix0rs-gnu-social.git/blobdiff - plugins/TwitterBridge/twittersettings.php
Show photos on all of a user's pages
[quix0rs-gnu-social.git] / plugins / TwitterBridge / twittersettings.php
index 33c5eb65bb23c3c291022f2fd7f5589a6cf33511..c169172b0000f980c80137fabf130ad0975473c5 100644 (file)
@@ -285,6 +285,7 @@ class TwittersettingsAction extends ConnectSettingsAction
         }
 
         $original = clone($flink);
+        $wasReceiving = (bool)($original->noticesync & FOREIGN_NOTICE_RECV);
         $flink->set_flags($noticesend, $noticerecv, $replysync, $friendsync);
         $result = $flink->update($original);
 
@@ -294,6 +295,19 @@ class TwittersettingsAction extends ConnectSettingsAction
             return;
         }
 
+        if ($wasReceiving xor $noticerecv) {
+            $this->notifyDaemon($flink->foreign_id, $noticerecv);
+        }
+
         $this->showForm(_m('Twitter preferences saved.'), true);
     }
+
+    /**
+     * Tell the import daemon that we've updated a user's receive status.
+     */
+    function notifyDaemon($twitterUserId, $receiving)
+    {
+        // todo... should use control signals rather than queues
+    }
+
 }