Instead of removing the error, for consistency, leaving the error as-was

and replaced the message with something that may or may not be more
understandable :P
This commit is contained in:
Pedro Worcel 2014-03-31 20:19:23 +13:00
parent e7c3e4c5ac
commit bb10dfc505

View File

@ -60,8 +60,7 @@ class ODict:
key, they are cleared. key, they are cleared.
""" """
if isinstance(valuelist, basestring): if isinstance(valuelist, basestring):
# convert the string into a single element list. raise ValueError("Expected list instead of string. E.g. odict['elem'] = ['string1', 'string2']")
valuelist = [valuelist]
new = self._filter_lst(k, self.lst) new = self._filter_lst(k, self.lst)
for i in valuelist: for i in valuelist: