django-auditlog icon indicating copy to clipboard operation
django-auditlog copied to clipboard

LogUpdate entries can be created even when the object is not saved

Open hackoder opened this issue 5 months ago • 1 comments

Looks like log_update is connected to a pre_save signal, which can result in log entries being created even when the object does not get saved. Wouldn't post_save be more accurate?

hackoder avatar Dec 08 '23 15:12 hackoder

https://github.com/jazzband/django-auditlog/blob/master/auditlog/receivers.py#L56

by the conditional branching, the case 'log entry could be created even if not saved', will not occur

2ykwang avatar Dec 25 '23 10:12 2ykwang