feat(db): also reject TRUNCATE on audit_log (statement-level trigger)
This commit is contained in:
@@ -26,3 +26,7 @@ $$ LANGUAGE plpgsql;
|
||||
CREATE TRIGGER audit_log_immutable
|
||||
BEFORE UPDATE OR DELETE ON audit_log
|
||||
FOR EACH ROW EXECUTE FUNCTION audit_log_reject_mutation();
|
||||
|
||||
CREATE TRIGGER audit_log_no_truncate
|
||||
BEFORE TRUNCATE ON audit_log
|
||||
FOR EACH STATEMENT EXECUTE FUNCTION audit_log_reject_mutation();
|
||||
|
||||
Reference in New Issue
Block a user