]> git.mxchange.org Git - quix0rs-gnu-social.git/commitdiff
do not required that roles_to_groups be specified
authorCraig Andrews <candrews@integralblue.com>
Wed, 18 Nov 2009 21:41:38 +0000 (16:41 -0500)
committerCraig Andrews <candrews@integralblue.com>
Wed, 18 Nov 2009 21:41:38 +0000 (16:41 -0500)
plugins/LdapAuthorization/LdapAuthorizationPlugin.php
plugins/LdapAuthorization/README

index cf1347bed07ad4184f43ba6ce690adc0640a5dee..69357f8aad05b54ffff6eb4d9eadc64e6d2a3a17 100644 (file)
@@ -48,7 +48,7 @@ class LdapAuthorizationPlugin extends AuthorizationPlugin
     public $scope=null;
     public $provider_name = null;
     public $uniqueMember_attribute = null;
-    public $roles_to_groups = null;
+    public $roles_to_groups = array();
     public $login_group = null;
     public $attributes = array();
 
@@ -66,9 +66,6 @@ class LdapAuthorizationPlugin extends AuthorizationPlugin
         if(!isset($this->uniqueMember_attribute)){
             throw new Exception("uniqueMember_attribute must be set.");
         }
-        if(!isset($this->roles_to_groups)){
-            throw new Exception("roles_to_groups must be set.");
-        }
         if(!isset($this->attributes['username'])){
             throw new Exception("username attribute must be set.");
         }
index fcf1efa47eb6671ed8c695006d7b17ed83dfe912..44239d8e06faca03558284ddae6a9cce3edd2815 100644 (file)
@@ -16,7 +16,7 @@ authoritative (false): should this plugin be authoritative for
     authorization?
 uniqueMember_attribute ('uniqueMember')*: the attribute of a group
     that lists the DNs of its members
-roles_to_groups*: array that maps StatusNet roles to LDAP groups
+roles_to_groups: array that maps StatusNet roles to LDAP groups
     some StatusNet roles are: moderator, administrator, sandboxed, silenced
 login_group: if this is set to a group DN, only members of that group will be
     allowed to login