Commits

Anonymous committed 0d3b881

makes sure all kwargs are strs

  • Participants
  • Parent commits f79fecb

Comments (0)

Files changed (1)

djangotoolbox/fields.py

         if not isinstance(values, dict):
             return values
         module, model = values.pop('_module', None), values.pop('_model', None)
+        # Let's make sure keys are instances of str
+        values = dict([(str(k), v) for k,v in values.items()])
         if module is not None:
             return getattr(import_module(module), model)(**values)
         return self.embedded_model(**values)