Skip to content

Commit 6053638

Browse files
committed
allow delete attribute to be passed a value
1 parent 8a18267 commit 6053638

File tree

1 file changed

+2
-2
lines changed

1 file changed

+2
-2
lines changed

lib/net/ldap.rb

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -980,8 +980,8 @@ def replace_attribute(dn, attribute, value)
980980
#
981981
# dn = "cn=modifyme, dc=example, dc=com"
982982
# ldap.delete_attribute dn, :mail
983-
def delete_attribute(dn, attribute)
984-
modify(:dn => dn, :operations => [[:delete, attribute, nil]])
983+
def delete_attribute(dn, attribute, value=nil)
984+
modify(:dn => dn, :operations => [[:delete, attribute, value]])
985985
end
986986

987987
# Rename an entry on the remote DIS by changing the last RDN of its DN.

0 commit comments

Comments
 (0)