aboutsummaryrefslogtreecommitdiffstats
path: root/Zotlabs/Module
diff options
context:
space:
mode:
authorredmatrix <git@macgirvin.com>2016-07-04 21:33:25 -0700
committerredmatrix <git@macgirvin.com>2016-07-04 21:33:25 -0700
commite6224898d29b605da6751b6744f0e544250b600a (patch)
tree70b801be1984280b820fa66d61417c3a1f2f8519 /Zotlabs/Module
parentd566ffa678dc9f035a022304a82560b19495a838 (diff)
downloadvolse-hubzilla-e6224898d29b605da6751b6744f0e544250b600a.tar.gz
volse-hubzilla-e6224898d29b605da6751b6744f0e544250b600a.tar.bz2
volse-hubzilla-e6224898d29b605da6751b6744f0e544250b600a.zip
more heavy lifting on xtensible perms
Diffstat (limited to 'Zotlabs/Module')
-rw-r--r--Zotlabs/Module/Connedit.php11
-rw-r--r--Zotlabs/Module/Settings.php2
2 files changed, 8 insertions, 5 deletions
diff --git a/Zotlabs/Module/Connedit.php b/Zotlabs/Module/Connedit.php
index 4469330e8..a5c5175dc 100644
--- a/Zotlabs/Module/Connedit.php
+++ b/Zotlabs/Module/Connedit.php
@@ -197,8 +197,11 @@ class Connedit extends \Zotlabs\Web\Controller {
$role = get_pconfig(local_channel(),'system','permissions_role');
if($role) {
$x = get_role_perms($role);
- if($x['perms_accept'])
- $abook_my_perms = $x['perms_accept'];
+ if($x['perms_connect']) {
+ foreach($x['perms_connect'] as $p) {
+ set_abconfig(local_channel(),$orig_record[0]['abook_xchan'],'my_perms',$p,1);
+ }
+ }
}
}
@@ -374,8 +377,8 @@ class Connedit extends \Zotlabs\Web\Controller {
$role = get_pconfig(local_channel(),'system','permissions_role');
if($role) {
$x = get_role_perms($role);
- if($x['perms_accept'])
- $my_perms = $x['perms_accept'];
+ if($x['perms_connect'])
+ $my_perms = $x['perms_connect'];
}
$yes_no = array(t('No'),t('Yes'));
diff --git a/Zotlabs/Module/Settings.php b/Zotlabs/Module/Settings.php
index 5c9ff1db0..85da261fc 100644
--- a/Zotlabs/Module/Settings.php
+++ b/Zotlabs/Module/Settings.php
@@ -371,7 +371,7 @@ class Settings extends \Zotlabs\Web\Controller {
}
foreach($global_perms as $k => $v) {
- set_abconfig(local_channel(),$channel['channel_hash'],'my_perms',$k,((array_key_exists($k,$role_permissions['perms_accept'])) ? intval($role_permissions['perms_accept'][$k])));
+ set_abconfig(local_channel(),$channel['channel_hash'],'my_perms',$k,((array_key_exists($k,$role_permissions['perms_connect'])) ? 1 : 0));
}
set_pconfig(local_channel(),'system','autoperms',(($role_permissions['perms_auto']) ? intval($role_permissions['perms_accept']) : 0));