From: friendica Date: Mon, 25 Jun 2012 10:24:02 +0000 (-0700) Subject: service_class restrict facebook_connect X-Git-Url: https://git.mxchange.org/?a=commitdiff_plain;h=ae70cbe9c768316f89de77bef7d2c8750a611680;p=friendica-addons.git service_class restrict facebook_connect --- diff --git a/facebook.tgz b/facebook.tgz index cec2cec8..233e4eae 100644 Binary files a/facebook.tgz and b/facebook.tgz differ diff --git a/facebook/facebook.php b/facebook/facebook.php index 6ff2a2ef..11c87a32 100644 --- a/facebook/facebook.php +++ b/facebook/facebook.php @@ -509,6 +509,13 @@ function facebook_content(&$a) { return ''; } + + if(! service_class_allows(local_user(),'facebook_connect')) { + notice( t('Permission denied.') . EOL); + return upgrade_bool_message(); + } + + if($a->argc > 1 && $a->argv[1] === 'remove') { del_pconfig(local_user(),'facebook','post'); info( t('Facebook disabled') . EOL);