From: Rob van der Linde Date: Tue, 7 Nov 2023 20:13:04 +0000 (+1300) Subject: netcmd: silo member: update model docstrings and exception text X-Git-Tag: talloc-2.4.2~741 X-Git-Url: http://git.ipfire.org/gitweb.cgi?a=commitdiff_plain;h=047ddb10019c893381d37b6bc0186814e4e07252;p=thirdparty%2Fsamba.git netcmd: silo member: update model docstrings and exception text Signed-off-by: Rob van der Linde Reviewed-by: Douglas Bagnall Reviewed-by: Andrew Bartlett --- diff --git a/python/samba/netcmd/domain/models/auth_silo.py b/python/samba/netcmd/domain/models/auth_silo.py index ba1347153ac..f09b6a6654a 100644 --- a/python/samba/netcmd/domain/models/auth_silo.py +++ b/python/samba/netcmd/domain/models/auth_silo.py @@ -54,13 +54,13 @@ class AuthenticationSilo(Model): return "msDS-AuthNPolicySilo" def grant(self, ldb, member): - """Add a member to the Authentication Silo. + """Grant a member access to the Authentication Silo. Rather than saving the silo object and writing the entire member list out again, just add one member only. :param ldb: Ldb connection - :param member: Member to add to silo + :param member: Member to grant access to silo """ # Create a message with only an add member operation. message = Message(dn=self.dn) @@ -71,19 +71,19 @@ class AuthenticationSilo(Model): try: ldb.modify(message) except LdbError as e: - raise GrantMemberError(f"Failed to add silo member: {e}") + raise GrantMemberError(f"Failed to grant access to silo member: {e}") # If the modify operation was successful refresh members field. self.refresh(ldb, fields=["members"]) def revoke(self, ldb, member): - """Remove a member from the Authentication Silo. + """Revoke a member from the Authentication Silo. Rather than saving the silo object and writing the entire member list out again, just remove one member only. :param ldb: Ldb connection - :param member: Member to remove from silo + :param member: Member to revoke from silo """ # Create a message with only a remove member operation. message = Message(dn=self.dn)