Allow other modules to alter the query when returning valid contact form emails

Created on 6 September 2017, about 7 years ago
Updated 18 December 2023, 9 months ago

In a project, we have a need to add some custom conditions to contact emails besides the default, which returns all enabled contact emails for a form. In our case we have a multi-regional (in addition to multi-lingual) site and each region wants to handle their form emails differently.

I found an easy way to do this by introducing a simple event in contact_emails that allows other modules to alter the query that's used. I'm testing this locally now and will submit a patch for review after that.

✨ Feature request
Status

Needs work

Version

1.0

Component

Code

Created by

πŸ‡ΊπŸ‡ΈUnited States bmcclure West Virginia

Live updates comments and jobs are added and updated live.
  • Needs tests

    The change is currently missing an automated test that fails when run with the original code, and succeeds when the bug has been fixed.

Sign in to follow issues

Comments & Activities

Not all content is available!

It's likely this issue predates Contrib.social: some issue and comment data are missing.

Production build 0.71.5 2024