mirror of https://gitlab.crans.org/nounous/nixos
fix category lockdown
parent
9571f9514d
commit
c1910e9098
|
|
@ -1,8 +1,8 @@
|
|||
diff --git a/CategoryLockdown.php b/CategoryLockdown.php
|
||||
index 1e17ec7..8108615 100644
|
||||
index 1e17ec7..b884553 100644
|
||||
--- a/CategoryLockdown.php
|
||||
+++ b/CategoryLockdown.php
|
||||
@@ -16,6 +16,8 @@ class CategoryLockdown {
|
||||
@@ -16,16 +16,23 @@ class CategoryLockdown {
|
||||
*/
|
||||
public static function onGetUserPermissionsErrors( $title, $user, $action, &$result ) {
|
||||
global $wgCategoryLockdown;
|
||||
|
|
@ -11,7 +11,11 @@ index 1e17ec7..8108615 100644
|
|||
|
||||
$explicitGroups = MediaWikiServices::getInstance()->getUserGroupManager()->getUserGroups( $user );
|
||||
$implicitGroups = MediaWikiServices::getInstance()->getUserGroupManager()->getUserImplicitGroups( $user );
|
||||
@@ -26,6 +28,11 @@ class CategoryLockdown {
|
||||
- $userGroups = $explicitGroups + $implicitGroups;
|
||||
+ $userGroups = array_merge( $explicitGroups, $implicitGroups );
|
||||
|
||||
// Rules don't apply to admins
|
||||
if ( in_array( 'sysop', $userGroups ) ) {
|
||||
return;
|
||||
}
|
||||
|
||||
|
|
|
|||
Loading…
Reference in New Issue