E-mail not send when opt_in_status is set but empty

Created on 1 October 2019, almost 5 years ago
Updated 22 July 2023, about 1 year ago

Hello,

I store opt_in_status in a value field.
It is not correctly filled because of this condition: https://git.drupalcode.org/project/webform_double_opt_in/blob/c723761a32...

In my case, $submissionData['opt_in_status'] is set but is empty, so I think the condition should also apply if the field is empty.

The workaround I found was to add a default value of "Double opt-in confirmation mail pending" to my field so the e-mail is correctly triggered.

(Of course, if the module creates the opt_in_status field automatically in the future, it should solve this issue.)

🐛 Bug report
Status

Postponed

Version

1.0

Component

Code

Created by

🇫🇷France prudloff Lille

Live updates comments and jobs are added and updated live.
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.

  • 🇩🇪Germany gogowitsch

    Meanwhile, we end-users can add the following lines to the form under Build » Source:

    opt_in_status:
      '#type': value
      '#title': opt_in_status
      '#value': 'Double opt-in confirmation mail pending'

    Also, I figured out that of the 2 handlers this module provides, only the DoubleOptInEmailWebformHandler is useful. The “Compatible“ handler doesn’t yet understand the [email-confirmer:confirmation-url] token as far as I can tell. In fact, it looks like the “Compatible“ handler is just an old copy of the one that is shipped with the vanilla webform module.

    And in short, I got the module to work and am happy.

Production build 0.71.5 2024