Commits

Jean-Tiare Le Bigot committed 4c0d01b

fix bug #14 'range_key logging in save'; thx Merwok

Comments (0)

Files changed (1)

dynamodb_mapper/model.py

         self._raw_data = self._to_db_dict()
 
         hash_key_value = getattr(self, hash_key)
-        range_key_value = getattr(self, hash_key, None)
+        range_key_value = getattr(self, range_key, None) if range_key else None
         dblog.debug("Saved (%s, %s) in table %s raise_on_conflict=%s", hash_key_value, range_key_value, cls.__table__, raise_on_conflict)
 
     def delete(self, raise_on_conflict=False):