diff options
author | Mario <mario@mariovavti.com> | 2021-04-08 20:01:56 +0000 |
---|---|---|
committer | Mario <mario@mariovavti.com> | 2021-04-08 20:01:56 +0000 |
commit | a34d8852b6695086ef3c9f5ff882d0d033f7d4a5 (patch) | |
tree | 1b659c2225d28cc717e98c22f2d3c95e494154e8 | |
parent | 18b6d48944be414acc179fb82f458f996810e5a3 (diff) | |
download | volse-hubzilla-a34d8852b6695086ef3c9f5ff882d0d033f7d4a5.tar.gz volse-hubzilla-a34d8852b6695086ef3c9f5ff882d0d033f7d4a5.tar.bz2 volse-hubzilla-a34d8852b6695086ef3c9f5ff882d0d033f7d4a5.zip |
minor revert
-rw-r--r-- | Zotlabs/Module/Register.php | 10 |
1 files changed, 8 insertions, 2 deletions
diff --git a/Zotlabs/Module/Register.php b/Zotlabs/Module/Register.php index c1355eba7..9d2a8aa96 100644 --- a/Zotlabs/Module/Register.php +++ b/Zotlabs/Module/Register.php @@ -222,9 +222,15 @@ class Register extends Controller { if ($reg['reg_startup'] <= $now && $reg['reg_expires'] >= $now) { + // is invitor admin + $isa = get_account_by_id($reg['reg_uid']); + $isa = ( $isa && ($isa['account_roles'] && ACCOUNT_ROLE_ADMIN) ); + // FIXME: set the correct flags if invitee is admin so we do not need to approve anyway if approve is on - //if (is_sys_channel($reg['reg_uid']) && $policy == REGISTER_APPROVE) - // $flags &= $flags ^ ACCOUNT_PENDING; + // approve contra invite by admin + if ($isa && $policy == REGISTER_APPROVE) + $flags &= $flags ^ ACCOUNT_PENDING; + if ($auto_create) { $reonar['chan.name'] = notags(trim($arr['name'])); |