odict: don't convert values to strings when added

This commit is contained in:
Aldo Cortesi 2015-04-14 16:20:02 +12:00
parent d739882bf2
commit aeebf31927
1 changed files with 2 additions and 2 deletions

View File

@ -84,7 +84,7 @@ class ODict(object):
return False
def add(self, key, value):
self.lst.append([key, str(value)])
self.lst.append([key, value])
def get(self, k, d=None):
if k in self:
@ -117,7 +117,7 @@ class ODict(object):
def __repr__(self):
elements = []
for itm in self.lst:
elements.append(itm[0] + ": " + itm[1])
elements.append(itm[0] + ": " + str(itm[1]))
elements.append("")
return "\r\n".join(elements)