sjelfull / craft-audit

Audit log for Craft 3
https://superbig.co
Other
20 stars 11 forks source link

Pruning old records does nothing #46

Closed piotrpog closed 5 years ago

piotrpog commented 5 years ago

I noticed it on version 1.0.4 of plugin and 3.0.32 of craft. Audit record base grew to 60 mb. When i tried to prune records using control panel button, message about succesfull delete appeared. But no records were removed. When i tried again, it showed "succesfuly removed 0 records". Uninstalling plugin finally pruned audit_log table in database. I just worry that plugin deleted something else instead of its records :)

sjelfull commented 5 years ago

It will never delete anything from other tables besides its own, but this should work.

The records, is any of them older than x days (by default 30 days)?

I'm also planning on adding a max n records, so that it will always keep the amount of records below a certain threshold.

piotrpog commented 5 years ago

I am at 90% certain that some of these records were older than 30 days. Unfortunetly i am not able to verify this with 100% certainty.

sjelfull commented 5 years ago

Let me know if you see this behaviour again.