Support for Drupal 7 is ending on 5 January 2025—it’s time to migrate to Drupal 10! Learn about the many benefits of Drupal 10 and find migration tools in our resource center.
Bug was introduced in #1827980: Post module enable/disable requirements (README): Account settings - E-mails require manual update
Account settings form validation fails if mail body template begins with [user:name-raw] token.
Relates to following mail templates:
- Welcome (new user created by administrator) - email_admin_created -
- Welcome (no approval required) - email_no_approval_required
- Account activation - email_activated
There are also incorrect checks in hook_requirements().
Comment | File | Size | Author |
---|---|---|---|
#4 | interdiff.txt | 2.14 KB | AndreyMaximov |
#4 | realname-account_settings_form_fails_validation-2142507-4.patch | 2.7 KB | AndreyMaximov |
#1 | realname-account_settings_form_fails_validation-2142507-1.patch | 645 bytes | AndreyMaximov |
Comments
Comment #1
AndreyMaximov CreditAttribution: AndreyMaximov commentedComment #2
AndreyMaximov CreditAttribution: AndreyMaximov commentedComment #3
maximpodorov CreditAttribution: maximpodorov commentedObvious fix. Please commit.
Comment #4
AndreyMaximov CreditAttribution: AndreyMaximov commentedThere are also incorrect checks in hook_requirements() resulting in red rows in status report.
Comment #5
AndreyMaximov CreditAttribution: AndreyMaximov commentedComment #6
dpovshed CreditAttribution: dpovshed commentedFix in #4 looks fine with me.
Comment #7
andypostgood to go!
Comment #8
aclubb CreditAttribution: aclubb commentedWhile this fix looks fine for what it does, there are sites which may be using both RealName and e.g. Email Registration modules, which will not want to include [user:name-raw] anywhere in the registration email, but instead use e.g. [user:mail]. The current approach prevents changes to registration emails for such sites, unless the unwanted [user:name-raw] is added.
While understand don't want users installing the RealName module to end-up with misleading registration emails, at least those are fixable, while the resolution breaks existing functionality. Would it be possible to look at modifying to provide REQUIREMENT_WARNINGs instead, so that sites installing are informed that they need to modify their email templates, whilst not breaking things for sites that don't want to have [user:name-raw] in the templates.
Comment #9
maximpodorov CreditAttribution: maximpodorov commented@aclubb, you mention another issue which should not stop fixing this one.
Comment #10
aclubb CreditAttribution: aclubb commented@maximpodorov - fair enough - will open another issue
Comment #11
hass CreditAttribution: hass commentedhttp://drupalcode.org/project/realname.git/commit/69582ab