save(force_update=True) crashes with model inheritance
|Reported by:||Lorenzo Gil Sanchez||Owned by:||nobody|
|Component:||Database layer (models, ORM)||Version:||1.0|
|Has patch:||yes||Needs documentation:||no|
|Needs tests:||no||Patch needs improvement:||yes|
When there is a subclass with no fields and you try to save it with obj.save(force_update=True) it will crash with this exception:
AttributeError: 'NoneType' object has no attribute 'rowcount'
The problem is that an or condition should be an and instead. I'm talking about the check in Model.save_base that test if there are non primary fields to save. This is better explained by the patch itself.