summaryrefslogtreecommitdiffstats
path: root/ipaserver
diff options
context:
space:
mode:
authorJan Cholasta <jcholast@redhat.com>2013-02-11 16:29:33 +0100
committerMartin Kosek <mkosek@redhat.com>2013-10-31 18:09:51 +0100
commita7180ed021b2ed55949eb98f54e3f4593bc9cecf (patch)
tree8367ceb6f28323852cd1927172d23cc8a2690f4f /ipaserver
parent463407ac6fb683b85866e39080cebe47b8c89fbc (diff)
downloadfreeipa-a7180ed021b2ed55949eb98f54e3f4593bc9cecf.tar.gz
freeipa-a7180ed021b2ed55949eb98f54e3f4593bc9cecf.tar.xz
freeipa-a7180ed021b2ed55949eb98f54e3f4593bc9cecf.zip
Remove legacy toDict and origDataDict methods of LDAPEntry.
https://fedorahosted.org/freeipa/ticket/3521
Diffstat (limited to 'ipaserver')
-rw-r--r--ipaserver/install/krbinstance.py4
-rw-r--r--ipaserver/install/ldapupdate.py7
2 files changed, 5 insertions, 6 deletions
diff --git a/ipaserver/install/krbinstance.py b/ipaserver/install/krbinstance.py
index a16e4d5f..cd39b827 100644
--- a/ipaserver/install/krbinstance.py
+++ b/ipaserver/install/krbinstance.py
@@ -123,10 +123,10 @@ class KrbInstance(service.Service):
ipauniqueid=['autogenerate'],
managedby=[host_dn],
)
- if 'krbpasswordexpiration' in service_entry.toDict():
+ if 'krbpasswordexpiration' in service_entry:
host_entry['krbpasswordexpiration'] = service_entry[
'krbpasswordexpiration']
- if 'krbticketflags' in service_entry.toDict():
+ if 'krbticketflags' in service_entry:
host_entry['krbticketflags'] = service_entry['krbticketflags']
self.admin_conn.add_entry(host_entry)
diff --git a/ipaserver/install/ldapupdate.py b/ipaserver/install/ldapupdate.py
index 35191e7a..34dd3a5e 100644
--- a/ipaserver/install/ldapupdate.py
+++ b/ipaserver/install/ldapupdate.py
@@ -809,11 +809,10 @@ class LDAPUpdate:
else:
# Update LDAP
try:
- changes = self.conn.generateModList(entry.origDataDict(), entry.toDict())
+ changes = self.conn.generateModList(entry.orig_data, entry)
if (entry.dn == DN(('cn', 'schema'))):
d = dict()
- e = entry.toDict()
- for k,v in e.items():
+ for k,v in entry.items():
d[k] = [str(x) for x in v]
updated = self.is_schema_updated(d)
else:
@@ -825,7 +824,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.origDataDict(), entry.toDict())
+ self.conn.updateEntry(entry.dn, entry.orig_data, entry)
self.info("Done")
except errors.EmptyModlist:
self.info("Entry already up-to-date")