Thread:Extension talk:Lockdown/Making lockdown function

I have lockdown working fine using this: $wgExtraNamespaces[100] = "Hide"; $wgExtraNamespaces[101] = "Hide_Talk"; $wgGroupPermissions['Hide'] = $wgGroupPermissions['user']; $wgNamespacePermissionLockdown[100]['*'] = array('Hide'); $wgNamespacePermissionLockdown[101]['*'] = array('Hide');

I have to lockdown a BUNCH of namespaces and there are many admins on the site. So, I had the idea to write this function: function make_lockdown_space($id, $name) {    global $wgExtraNamespaces, $wgGroupPermissions, $wgNamespacePermissionLockdown; $wgExtraNamespaces[$id] = $name; $wgExtraNamespaces[$id+1] = $name."_Talk"; $wgGroupPermissions[$name] = $wgGroupPermissions['user']; $wgNamespacePermissionLockdown[$id]['*'] = array($name); $wgNamespacePermissionLockdown[$id+1]['*'] = array($name); }

With this function, I theoretically only need: make_lockdown_space(100, "Hide");

With that function, I check all the arrays. All are set. All look good. However, there is no lockdown. Anyone can see the namespaces that are supposedly locked down. Why? I don't see how it is possible that the arrays are altered without a problem, but lockdown fails. Anyone know what is happening?