Make it more explicit which argument is the key_fields
Patch by: Sverre Rabbelier
--- a/app/soc/logic/models/base.py Thu Feb 26 09:02:51 2009 +0000
+++ b/app/soc/logic/models/base.py Thu Feb 26 16:45:18 2009 +0000
@@ -412,12 +412,12 @@
return entity
- def updateOrCreateFromFields(self, properties, fields):
+ def updateOrCreateFromFields(self, properties, key_fields):
"""Like updateOrCreateFromKeyName, but resolves fields to a key_name first.
"""
# attempt to retrieve the existing entity
- key_name = self.getKeyNameFromFields(fields)
+ key_name = self.getKeyNameFromFields(key_fields)
return self.updateOrCreateFromKeyName(properties, key_name)