Lua primitives: mail_filter()
If you define a command via mail_filter it will be invoked on every email message prior to further processing.
The flow of execution goes something like this:
- Find the mail message.
- If mail_filter() is set, use it.
- Parse the message looking for the first text/plain part. This will be the message body.
- Display the message body
- Optionally invoking display_filter.
This function has been available since version 0.18.