mirror of
https://github.com/ArchiveBox/ArchiveBox
synced 2024-11-10 06:34:16 +00:00
prevent ABID drift entirely when its set to False on a model
This commit is contained in:
parent
c76c50e71f
commit
26291f81ef
1 changed files with 1 additions and 0 deletions
|
@ -152,6 +152,7 @@ class ABIDModel(models.Model):
|
|||
else:
|
||||
print(f'\n#### WARNING: ABID of existing record is outdated and has not been updated ({self.__class__.__name__}.abid_drift_allowed={self.abid_drift_allowed})')
|
||||
print(change_error)
|
||||
raise change_error
|
||||
|
||||
def save(self, *args: Any, abid_drift_allowed: bool | None=None, **kwargs: Any) -> None:
|
||||
"""Overriden save method ensures new ABID is generated while a new object is first saving."""
|
||||
|
|
Loading…
Reference in a new issue