File tree Expand file tree Collapse file tree 1 file changed +6
-1
lines changed Expand file tree Collapse file tree 1 file changed +6
-1
lines changed Original file line number Diff line number Diff line change @@ -69,14 +69,19 @@ def member_names
69
69
end
70
70
end
71
71
72
+ # Internal: Returns true if the object class(es) provided match a group's.
73
+ def group? ( object_class )
74
+ self . class . group? ( object_class )
75
+ end
76
+
72
77
# Internal - Check if an object class includes the member names
73
78
# Use `&` rathen than `include?` because both are arrays.
74
79
#
75
80
# NOTE: object classes are downcased by default in Net::LDAP, so this
76
81
# will fail to match correctly unless we also downcase our group classes.
77
82
#
78
83
# Returns true if the object class includes one of the group class names.
79
- def group? ( object_class )
84
+ def self . group? ( object_class )
80
85
!( GROUP_CLASS_NAMES . map ( &:downcase ) & object_class . map ( &:downcase ) ) . empty?
81
86
end
82
87
You can’t perform that action at this time.
0 commit comments