aboutsummaryrefslogtreecommitdiffstats
path: root/mod/register.php
diff options
context:
space:
mode:
Diffstat (limited to 'mod/register.php')
-rw-r--r--mod/register.php8
1 files changed, 7 insertions, 1 deletions
diff --git a/mod/register.php b/mod/register.php
index 890bc69b7..6f0469db8 100644
--- a/mod/register.php
+++ b/mod/register.php
@@ -250,7 +250,13 @@ function register_post(&$a) {
if(! function_exists('register_content')) {
function register_content(&$a) {
- if($a->config['register_policy'] == REGISTER_CLOSED) {
+ // logged in users can register others (people/pages/groups)
+ // even with closed registrations, unless specifically prohibited by site policy.
+ // 'block_extended_register' blocks all registrations, period.
+
+ $block = get_config('system','block_extended_register');
+
+ if((($a->config['register_policy'] == REGISTER_CLOSED) && (! getuid())) || ($block)) {
notice("Permission denied." . EOL);
return;
}