Needs work
Project:
Variable
Version:
7.x-2.x-dev
Component:
Code
Priority:
Normal
Category:
Bug report
Assigned:
Unassigned
Reporter:
Created:
8 Feb 2013 at 23:24 UTC
Updated:
15 Jul 2013 at 09:49 UTC
Jump to comment: Most recent file
Currently, its not possible to override the default values for the user_mail variables. These get pulled directly from the _user_mail_text function.
| Comment | File | Size | Author |
|---|---|---|---|
| #3 | 1912408.3-variable-user_mail-override-default.patch | 623 bytes | mrfelton |
| #1 | 1912408-variable-user_mail-override-default.patch | 540 bytes | mrfelton |
Comments
Comment #1
mrfelton commentedAttached patch lets you override override the default, similar to how variable_email lets you set/override the defaults for it's html_mail type variables.
Example usage, where we override the user_mail_register_no_approval_required_body default to be compatible with logintoboggan.
Comment #2
mrfelton commentedThis is not working properly - it seems that the tokens from the default text are being parsed at the wrong time. For example, with no value for user_mail_password_reset_body stored in the database, when you go to edit the variable through the variable_admin interface, the tokens have already been processed.
Comment #3
mrfelton commentedUpdated patch resolves issue from #2
Comment #4
jose reyero commentedThe idea looks good, though this isssue is not specific of user mail variables.
Maybe we should fix variable_get_default() instead to check for $variable['default'] before 'default callback' ?