mirror of
https://github.com/samba-team/samba.git
synced 2025-01-24 02:04:21 +03:00
python/samdb: Allow samdb.normalize_dn_in_domain() to take an ldb.Dn()
Signed-off-by: Andrew Bartlett <abartlet@samba.org> Reviewed-by: Douglas Bagnall <douglas.bagnall@catalyst.net.nz>
This commit is contained in:
parent
0a88be836b
commit
3f022b2dd0
@ -1004,6 +1004,10 @@ accountExpires: %u
|
||||
:param dn: relative dn
|
||||
"""
|
||||
domain_dn = ldb.Dn(self, self.domain_dn())
|
||||
|
||||
if isinstance(dn, ldb.Dn):
|
||||
dn = str(dn)
|
||||
|
||||
full_dn = ldb.Dn(self, dn)
|
||||
if not full_dn.is_child_of(domain_dn):
|
||||
full_dn.add_base(domain_dn)
|
||||
|
Loading…
x
Reference in New Issue
Block a user