Use LDAPClient.update_entry for LDAP mods in ldapupdate.

Remove legacy IPAdmin methods generateModList and updateEntry.

https://fedorahosted.org/freeipa/ticket/3488
This commit is contained in:
Jan Cholasta authored and Petr Viktorin committed 2014-01-10 14:41:39 +01:00
1 parent 8d67acc026
commit 21fab665f4
2 files changed
+2 -62

No files matched your search

+2 -2
View File
@@ -722,7 +722,7 @@ class LDAPUpdate:
else:
# Update LDAP
try:
changes = self.conn.generateModList(entry.orig_data, entry)
changes = self.conn._generate_modlist(entry.dn, entry)
if len(changes) >= 1:
updated = True
safe_changes = []
@@ -731,7 +731,7 @@ class LDAPUpdate:
self.debug("%s" % safe_changes)
self.debug("Live %d, updated %d" % (self.live_run, updated))
if self.live_run and updated:
self.conn.updateEntry(entry.dn, entry.orig_data, entry)
self.conn.update_entry(entry)
self.info("Done")
except errors.EmptyModlist:
self.info("Entry already up-to-date")