Ensure that various rules set a reason.
Fixes #368 (closed)
Several rules do not set a moderation_reason
resulting in holds and rejects with reason "N/A". This MR adds moderation_reasons
and where applicable moderation_sender
and moderation_action
to the various rules than can cause a message to be held, rejected or discarded. It also adds tests for moderation_reasons
being set.
Some of these attributes are not currently used in all these cases, but I don't think it hurts to add them in case we want to implement increased logging in the future.
Note: I have unchecked Remove source branch when merge request is accepted.
in case that helps with possible backporting.