Changes between Version 2 and Version 3 of Ticket #28385, comment 5
- Timestamp:
- Jul 23, 2017, 9:52:22 AM (7 years ago)
Legend:
- Unmodified
- Added
- Removed
- Modified
-
Ticket #28385, comment 5
v2 v3 16 16 > if obj.pk is None or (hasattr(Model, 'natural_key') and hasattr(Model._default_manager, 'get_by_natural_key')): 17 17 18 If `pk` is set - it updates model via `return obj` without `updating pk` logic. 19 If `pk` isn't set as like as `natural key` implementation - it updates model via `return obj` without `updating pk` logic. 20 21 If `pk` isn't set, but `natural key` implementation exists - go to `updating pk` logic. 18 If `pk` isn't set, but `natural key` implementation exists - it goes to `updating pk` logic. 22 19 23 20 I did test manually, it seems bug is fixed.