]> git.mxchange.org Git - quix0rs-gnu-social.git/commitdiff
Automatically make Facebook admin panel available if the FacebookBridge
authorZach Copley <zach@status.net>
Fri, 19 Nov 2010 05:55:43 +0000 (21:55 -0800)
committerZach Copley <zach@status.net>
Fri, 19 Nov 2010 05:55:43 +0000 (21:55 -0800)
plugin is installed.

plugins/FacebookBridge/FacebookBridgePlugin.php

index 80a31d9cb1a93331a0cde74f773c895319b36359..8b5d05e98359251aadf3e317a28779d3a9603628 100644 (file)
@@ -208,6 +208,19 @@ class FacebookBridgePlugin extends Plugin
         return true;
     }
 
+    /**
+     * If the plugin's installed, this should be accessible to admins
+     */
+    function onAdminPanelCheck($name, &$isOK)
+    {
+        if ($name == 'facebook') {
+            $isOK = true;
+            return false;
+        }
+
+        return true;
+    }
+
     /**
      * Add a Facebook tab to the admin panels
      *
@@ -483,7 +496,7 @@ ENDOFSCRIPT;
     {
         $client = new Facebookclient($notice);
         $client->streamRemove();
-        
+
         return true;
     }