22:41 (4 ч. назад)
кому: мне
Email Registration will allow users to login with their username instead of their email address. The documentation seems to imply that this is not the intended behavior but it seems like some people might want it.
We should make it a toggle-able setting, ideally on a form that already exists like admin/config/people and the variable can be called email_registration_login_with_username
The default should be that people can only login with their email.
Originally this had some other fixes. Those are now covered by distinct issues: #1874454: Make the name a value instead of a hidden to keep it from being in the HTML and #421078: Abstract name unique check for re-use, make it is cross-database compatible, make it more robust, us it on external names.
Comment | File | Size | Author |
---|---|---|---|
#132 | interdiff.txt | 613 bytes | JeroenT |
#132 | add_setting_to_allow-657472-132.patch | 7.92 KB | JeroenT |
Comments
Comment #1
derekdunagan CreditAttribution: derekdunagan commentedAfter reviewing the discussion in #625734: Move logic for converting email to username into a separate function, I've created a second patch that makes
email_registration_generate_name()
return the "hooked" version of the generated username and_email_registration_generate_name()
return the default version.Comment #2
Bilmar CreditAttribution: Bilmar commentedsubscribing
Comment #3
work77 CreditAttribution: work77 commentedI just ran the patch and got the following message. Any suggestions? Is there a specific point at which I should have run the patch. For what it's worth, I first installed email_registration. Didn't use it. Then I disabled the module. Then I ran the patch and got the following.
"Hunk #1 succeeded at 2 with fuzz 1.
patching file email_registration.module
Hunk #1 FAILED at 14.
Hunk #2 succeeded at 27 (offset -15 lines).
Hunk #3 succeeded at 54 (offset -15 lines).
Hunk #4 succeeded at 96 (offset -7 lines).
1 out of 4 hunks FAILED -- saving rejects to file email_registration.module.rej"
this is what is in email_registration.module.rej...
<?
***************
*** 14,51 ****
function email_registration_user($op, &$edit, &$account, $category = NULL) {
switch ($op) {
case 'insert':
- // Other modules may implement hook_email_registration_name($edit, $account)
- // to generate a username (return a string to be used as the username, NULL
- // to have email_registration generate it)
- $names = module_invoke_all('email_registration_name', $edit, $account);
- // Remove any empty entries
- $names = array_filter($names);
-
- if (empty($names)) {
- // Default implementation of name generation
- $namenew = preg_replace('/@.*$/', '', $edit['mail']);
- // if username generated from email record already exists, append underscore and number eg:(chris_123)
- if (db_result(db_query("SELECT count(*) FROM {users} WHERE uid <> %d AND LOWER(name) = LOWER('%s')", $account->uid, $namenew)) > 0) {
- // find the next number available to append to the name
- $sql = "SELECT SUBSTRING_INDEX(name,'_',-1) FROM {users} WHERE name REGEXP '%s' ORDER BY CAST(SUBSTRING_INDEX(name,'_',-1) AS UNSIGNED) DESC LIMIT 1";
- $nameidx = db_result(db_query($sql, '^'. $namenew .'_[0-9]+$'));
- $namenew .= '_'. ($nameidx + 1);
- }
- }
- else {
- // One would expect a single implementation of the hook, but if there
- // are multiples out there use the last one
- $namenew = array_pop($names);
- }
- // replace with generated username
if (db_query("UPDATE {users} SET name = '%s' WHERE uid = '%s'", $namenew, $account->uid)) {
$edit['name'] = $namenew; // update in the user array for access by other modules
}
- // if email verification is off and a new user is the one creating account, log the new user in with correct name
global $user;
- if (!variable_get('user_email_verification', 1) && $user->uid == 0) {
$user = $account;
$user->name = $namenew;
}
--- 14,30 ----
function email_registration_user($op, &$edit, &$account, $category = NULL) {
switch ($op) {
case 'insert':
+ $namenew = email_registration_generate_name($edit, $account);
+
+ // Replace with generated username
if (db_query("UPDATE {users} SET name = '%s' WHERE uid = '%s'", $namenew, $account->uid)) {
$edit['name'] = $namenew; // update in the user array for access by other modules
}
+ // If email verification is off and a new user is the one creating account, log the new user in with correct name
global $user;
+ if (!variable_get('user_email_verification', 1) && $user->uid == 0) {
$user = $account;
$user->name = $namenew;
}
?>
sorry. Just noticed this should have been posted under 'support'.
Comment #4
stella CreditAttribution: stella commentedPatch re-roll. It also updates the text on the user login form to reflect the code changes.
Comment #5
YK85 CreditAttribution: YK85 commentedHello,
Thank you very much on your hard work. The patch at #4 against the latest dev resulted in the below error.
Can the patch at #4 be brought up to the latest dev? I look forward to testing this. Thanks!
patching file email_registration.module
Hunk #1 FAILED at 14.
Hunk #2 succeeded at 45 (offset 3 lines).
Hunk #3 succeeded at 63 (offset 4 lines).
Hunk #4 succeeded at 80 (offset 4 lines).
Hunk #5 succeeded at 144 (offset 34 lines).
1 out of 5 hunks FAILED -- saving rejects to file email_registration.module.rej
can't find file to patch at input line 189
Perhaps you used the wrong -p or --strip option?
The text leading up to this was:
--------------------------
|Index: email_registration.install
|===================================================================
|--- email_registration.install (revision 144)
|+++ email_registration.install (working copy)
Comment #6
stella CreditAttribution: stella commentedPatch re-roll
Comment #7
krutipatel CreditAttribution: krutipatel commentedHello,
i have install Email Registration module but still its allowing me to login using the username.
Thanks,
Kruti
Comment #8
Christopher Herberte CreditAttribution: Christopher Herberte commented#6 stella, patch failed. otherwise RTBC.
Comment #9
YK85 CreditAttribution: YK85 commentedmay the patch at #6 be re-rolled?
@Chris - is there a good chance of this option being implemented in Email Registration module?
Thanks!
Comment #10
john.money CreditAttribution: john.money commented+1 on adding this to Email Registration
Attached is patch #4 rerolled against 1.3 (since .install was removed from -dev).
Comment #12
robby.smith CreditAttribution: robby.smith commentedsubscribing
Comment #13
YK85 CreditAttribution: YK85 commentedPatch applied smoothly and I see the "Allow users to login with their email address OR their username" setting in User settings.
I have the setting unchecked so that users must enter their email address.
I'm seeing an issue when a user tries to log in with an unknown email address.
Without applying the patch the user gets the below warning message, which makes sense:
After applying the patch the user gets the below warning message, which does not make sense:
Can this issue be looked into? I appreciate the support!
Comment #14
YK85 CreditAttribution: YK85 commentedAny chance someone could look into the issue of the unrecognized email message being changed after the patch is applied? I'm available for heavy testing and would like to see this committed into the module. Thanks!
Comment #15
robby.smith CreditAttribution: robby.smith commentedAny updates in this development?
Comment #16
iamjon CreditAttribution: iamjon commentedSubscribing
Comment #17
YK85 CreditAttribution: YK85 commentedWould anyone be able to kindly look into finalizing the patch?
Comment #18
robby.smith CreditAttribution: robby.smith commentedI guess this should be 'needs work' until #13 message issue is addressed?
Comment #19
chuckbar77 CreditAttribution: chuckbar77 commentedGreat module! It would be awesome to see it further develop to add these types of very useful features.
Thanks for all the hard work!
Comment #20
thePanz CreditAttribution: thePanz commentedIsn't this feature also available using LoginToboggan module? Seems that the two modules are overlapping in some parts :|
Comment #21
thePanz CreditAttribution: thePanz commentedRe-rel for the latest email_registration module
The settings now allow of fine tune the "login" process: admin can choose between:
1. username
2. username OR email
3 email only
Review needed and maybe some more simple test cases.
Notes: this patch integrates #421078-6: Abstract name unique check for re-use, make it is cross-database compatible, make it more robust, us it on external names patch for for cross-database query and some code-cleanups (done with Coder module)
Comment #22
pawel_r CreditAttribution: pawel_r commented#21 works fine! Still is one issue to solve: after registration 'username' is exactly the same as e-mail address, proper 'username' is no longer generated as it was originally.
[email: me@myhost.com -> username: me@myhost.com but should be username: me]
Comment #23
thePanz CreditAttribution: thePanz commentedI've fixed your issue (please check again) and implemented few more SimpleTests for the "login with email OR username" feature. No tests for "generate username" yet.
Please review the new patch
notes: unfortunately this patch also includes the following patches (with fixes)
#678434: Don't generate username if the account->user is already set
#421078: Abstract name unique check for re-use, make it is cross-database compatible, make it more robust, us it on external names
I can help as a co-maintainer if the module owner wants :)
Comment #24
pawel_r CreditAttribution: pawel_r commentedThere is sth wrong with that patch - it can be applied only to *.module file. Another issues:
1. during first log in two very short messages are displayed to user:
-- " array() "
-- " 'my_username' " where my_username is generated from e-mail address
2. registration confirm email (when user can log in only with e-mail address) should be override with email address instead of username (information given is wrong - user cannot log in with this username)
I tried to use this patched version (patch applied to email_registration.module) with 'login toboggan' and it seems that it is possible to use both at the same time (I'm talking about logging in with e-mails only).
Comment #25
thePanz CreditAttribution: thePanz commented@pawel_r : you're right, unfortunately I left some debug messages (using drupal_set_message() function) in the patch code :| I'm sorry
The attached patch should fix it
Comment #26
YK85 CreditAttribution: YK85 commentedhi thePanz, it would be AWESOME if you were able to support this module as co-maintainer.
I am not sure about the process but maybe opening up a new post in the queue requesting is the first step?
Thank you!
Comment #27
YK85 CreditAttribution: YK85 commentedPlease consider tackling #738134: Conflict with LoginToboggan submit handler
It seems to be one issue caused by specific code in Email Registration which doesn't play nice with other modules.
Many thanks
Comment #28
pawel_r CreditAttribution: pawel_r commented#25 thx I will try it this week. It would be great if you could prepare special patch that adds ER functionality to LT. In my opinion register with 'username' not with e-mail address is just 'obsolete' idea.
Comment #29
thePanz CreditAttribution: thePanz commented@pawel_r: unfortunately I fount LT's code a bit confusing (I sent a patch with a first code-cleanup, but the owner didn't accept it, sentencing that the stable branch for Drupal6 is in "code-freeze")..
I fount, instead, that ER is a great and simple module to deal with. Some functionality should be improved or fine-tuned, but it's almost great! :)
I'd like to help as a co-maintainer.. the module owner maybe will accept my "candidature" let see! :)
Regards
Comment #30
chuckbar77 CreditAttribution: chuckbar77 commentedthePanz - were you accepted as a co-maintainer? More development in ER would be great!
Comment #31
pawel_r CreditAttribution: pawel_r commentedPatch to be applied after patch given at #25. fully integrated with Login Toboggan 6.x-1.10 (couldn't spot any errors). It has not been tested with disabled Login Toboggan (always enabled).
EDIT actually it is not perfectly fine
Comment #32
chinita7 CreditAttribution: chinita7 commentedThanks for the patch #25 it works on my site. I have installed logintoboggan with option "Set password" and "Immediate login" but so far don't really see the error. What #31 is for? Is it a patch for http://drupal.org/node/738134?
By the way, if the maximum length of username is set by Access rules at my-site.com/admin/user/rules for example to 15 it gives error on the registration like this. I just removed this access rule I previously used to use and then the error is gone so it's not a really big deal.
"email_registration_bUSefQHSMf can't be registered. Username can only contain up to 15 characters and punctuation is not allowed except for periods, hyphens, and underscores. "
Comment #33
chinita7 CreditAttribution: chinita7 commentedI just noticed that I had to disable "Allow users to login using their e-mail address" option for logintoboggan to use "eMail only" option for email registration module. Otherwise the title and description of login form can't be override by email registration module.
Comment #34
gregglesSo, this patch does a lot of cleanup/style issues, which is certainly well intentioned, but kind of a bummer because it makes it harder to review. At a minimum it needs the $Id to be removed. It would be nice to get a reroll without the cleanup/reorganization stuff and move those to a separate issue.
Comment #35
gregglesI've now focused this issue down to just the specific feature and updated the issue summary to reflect that.
Here's an updated patch for 7.x that I think does the job.
thePanz had some code to add more complex user messages if they theoretically can use their username to login. In my opinion we should keep the text to a real minimum here.
One bug: If you try to login with a valid username, you get the message "The username has not been activated or is blocked."
I've also added some tests to cover these two settings.
Comment #36
gregglesAs I think about it more, I don't feel super strongly about this issue. If someone else can review the code, provide feedback and maybe fix the one bug I note in #35 that would be great.
Comment #37
iLLin CreditAttribution: iLLin commentedWhy not add an email validation handler to the form['name']['#element_validate'] and toggle there? As it currently stands now I can login with my email address or my username (which I want and I am happy with) but if you wanted to block username logins, that could be a lot easier as it will need to validate as a valid email address before any processing is done. The only thing with that is if the username is a valid email address. Then wuts it really matter?
Comment #38
joachim CreditAttribution: joachim commentedHere is a patch that:
- fixes the bug mentioned in #35
- changes the login forms to say 'E-mail or username' when a username is also an allowed option
- fixes inconsistencies in UI strings that the prior patch had (email/e-mail, full stops, etc)
Another minor point is that our new admin setting technically should not go in the 'Registration and cancellation' fieldset, since it's about neither. But I am loath to add a new fieldset for a single checkbox!
Comment #40
joachim CreditAttribution: joachim commentedUrgh. Will figure that out tomorrow!
Comment #41
joachim CreditAttribution: joachim commentedFixed. The test for logging in with just the username was passing in the $login array with the password from the first user the test created.
Comment #42
sukh.singh CreditAttribution: sukh.singh commentedThe last submitted patch, 657472.email_registration.allow-login-with-username.41.patch, worked for me. Only thing which I felt is missing is that if we can have toggle option available for login via username or email address on user setting page, that will make module more user friendly.
Comment #43
joachim CreditAttribution: joachim commentedThis part of the patch puts the option on the user settings page.
Comment #44
greggles@joachim - I think @nicesukhi1 was suggesting that it be an option within each user's control on a per-user basis on user/UID/edit. In my opinion that's more information than should be exposed to the individual user.
I agree conceptually with this issue though I haven't yet tested out the behavior of this patch yet.
Comment #45
gregglesI'm reviewing this now and have a question...which way should be the default?
Should the default be to allow both email and username (the current module behavior, but which would change user facing strings) or to only allow email (what the strings say, but NOT the behavior).
Comment #46
gregglesEverything works as expected, the code looks good, and it's pretty compact.
I decided that I'd rather have the UI strings change than the behavior of the site, so I flipped them all to true (and changed the tests and comments to match).
This is RTBC from me, but leaving Needs Review for a bit longer for others to review.
Comment #47
joachim CreditAttribution: joachim commentedIf I'm following this correctly:
- the basic intention of this module is to allow users to be blissfully ignorant of the concept of a 'username', and to hide that concept from them
- however, current behaviour of this module allows login with username, which is an unintended feature.
- therefore, the default for this new setting ought to be to NOT allow login with username.
- however, imposing the default as FALSE would change the behaviour of the module mid-cycle, which is bad.
- therefore, we compromise, and set the default to TRUE.
Is that a fair summary?
If so, this all seems sensible to me.
And presumably, we should file a follow-up to change the default to FALSE come D8?
Comment #48
gregglesYes, #47 is exactly how I feel.
Comment #48.0
gregglesfocus the issue on the one problem
Comment #49
SGhosh CreditAttribution: SGhosh commentedRe-rolling the patch from #46.
Comment #50
subhojit777Patch in #49 applied successfully on 7.x-1.x-dev version of this module. But it is working. I cannot find any setting where I can select username or email registration.
Comment #51
SGhosh CreditAttribution: SGhosh commented@subhojit777, the settings are under Account settings - /admin/config/people/accounts
'Allow users login with e-mail or username.'
The option is to allow users to either login using either username or email, or login only using email.
Comment #52
subhojit777Apologies, I was expecting the setting in a new page. Patch in #49 is working.
Comment #53
pinkonomy CreditAttribution: pinkonomy commentedEDIT:
Patch from 49 works.
Comment #54
jthorson CreditAttribution: jthorson commentedHmmm ... not sure why #49 is showing up as deleted ... re-uploading so it stops messing with testbot.
Comment #55
jthorson CreditAttribution: jthorson commentedComment #56
jthorson CreditAttribution: jthorson commentedComment #58
gregglesI just rolled a new release, so this seemed like a good time to add in this feature to get some testing. Then in a month or two we can make a new release of 7.x.
So, I've committed this! Thanks everyone for your work on this over the years (years!) that it took to get it in. I don't work on d6 any more so am moving this to fixed instead of backport. If someone wants to backport, please post the patch and set the status to needs review.
Comment #60
andypostThis commit break test, so I pushed fix, also cleaned up the test.
This needs to be ported to 8.x
EDIT probably #423920: [2.x] Prevent race condition in account generation code by adding uid to name caused the test breakage
Comment #61
grasmash CreditAttribution: grasmash as a volunteer commentedTaking a stab at 8.x-1.x patch.
Comment #63
grasmash CreditAttribution: grasmash as a volunteer commentedUpdating default values and fixing failing config set in test.
Comment #65
grasmash CreditAttribution: grasmash as a volunteer commentedTrying this one more time... maybe someone can suggest what could be causing failure. I've verified that the intended functionality has been achieved.
Comment #67
andypostI suppose most of failures caused by absence of default config and schema for it
when you introduce config it needs defaults in module & schema
also and upgrade path for existing sites
Comment #68
andypostComment #69
grasmash CreditAttribution: grasmash as a volunteer commentedOk, adding a config file.
My brief reading of Defining and using your own configuration in Drupal 8 seems to indicate that a schema file if translation is required. Since this is a boolean config value, I don't believe it is applicable.
Comment #71
grasmash CreditAttribution: grasmash as a volunteer commentedTurns out we do need a schema.yml.
Comment #73
grasmash CreditAttribution: grasmash as a volunteer commentedComment #75
andypostname of config in schema should be the same
I think default value should be FALSE to keep backward compatibility but having it TRUE make more sense from UX pov
Comment #76
andypostsorry xposted
Comment #77
andypostPlease use php 5.3 ternary op
$login_with_username = $config->get('login_with_username') ?: TRUE;
Comment #78
andypostBtw this condition always TRUe(
Comment #79
grasmash CreditAttribution: grasmash as a volunteer commentedWhy support 5.3 syntax if D8 doesn't support 5.3? Fixing config evaluation...
Comment #81
grasmash CreditAttribution: grasmash as a volunteer commentedSwitching default value to false.
Comment #82
grasmash CreditAttribution: grasmash as a volunteer commentedFixing login values.
Comment #85
grasmash CreditAttribution: grasmash as a volunteer commentedI'm going to guess that `$form_state->setValue('name', NULL);` isn't working out well. Will need to flag an error in some other way, e.g., $form_state->setErrorByName().
Comment #86
grasmash CreditAttribution: grasmash as a volunteer commentedNot sure why this one is failing. Manual testing appears to work fine.
Comment #88
svendecabooterUpdate the patch in #86:
* Fixed failing test
* Added UI to configure the newly introduced setting
Comment #89
JeroenTI think this change should be removed.
I also did some manual testing and login works with username and e-mail, so this patch is almost ready.
Comment #90
harsha012 CreditAttribution: harsha012 as a volunteer and at Red Crackle commentedFixed the changes.
Comment #91
JeroenT@harsha012,
Thanks for the patch, but there are a few files missing that are added in #88. Can you also add those files again?
There should be a newline at the end of this file.
Comment #92
JeroenTcore: 8.x should also be re-added to the email_registration.info.yml file.
Comment #93
harsha012 CreditAttribution: harsha012 as a volunteer and at Red Crackle commentedAdded the core version
Comment #94
harsha012 CreditAttribution: harsha012 as a volunteer and at Red Crackle commentedComment #97
JeroenT@harsha012,
Thanks for the patch, but the files added in #88 are still missing.
Newline is still missing. Can you please add it?
Comment #98
harsha012 CreditAttribution: harsha012 as a volunteer and at Red Crackle commentedFixed it.
Comment #99
harsha012 CreditAttribution: harsha012 as a volunteer and at Red Crackle commentedComment #101
JeroenT@harsha012,
The changes in email_registration.info.yml look great, but the following files are still missing:
Can you add please add those files back to the patch? You can find more information here: https://www.drupal.org/node/707484
Comment #102
harsha012 CreditAttribution: harsha012 as a volunteer and at Red Crackle commentedokay @JeroenT
Comment #103
harsha012 CreditAttribution: harsha012 as a volunteer and at Red Crackle commentedComment #104
harsha012 CreditAttribution: harsha012 as a volunteer and at Red Crackle commentedAdded files back to patch
Comment #105
harsha012 CreditAttribution: harsha012 as a volunteer and at Red Crackle commentedComment #106
JeroenT@harsha012,
Great to see the files are back.
There is still one problem, the following files have no newline at the end of the file:
but this can also be fixed on commit. marked as RTBC.
Comment #107
andypost@harsha012 please revert the patch to previous state - I mean #98 + config schema and default config to pass tests
Also it needs hook_update_N() for existing sites
@JeroenT separate form with one checkbox make no sense at all
still needs to be fixed
There's already checkbox for that setting so I see not actual reason to implement new form with single checkbox on it.
Moreover there's no upgrade path for existing sites in the patch...
Also new permission makes no sense because this setting could be changed in user administration form
Nitpick - this is used only once so no reason in separate variable,
I'm fine to keep it, because tests should be polished after #2066993: Use \Drupal consistently in tests
Comment #108
harsha012 CreditAttribution: harsha012 as a volunteer and at Red Crackle commentedComment #109
harsha012 CreditAttribution: harsha012 as a volunteer and at Red Crackle commentedAdded patch. please review.
Comment #110
harsha012 CreditAttribution: harsha012 as a volunteer and at Red Crackle commentedComment #111
andypostplease remove form with only one checkbox and move this checkbox to account settings form
Comment #112
harsha012 CreditAttribution: harsha012 as a volunteer and at Red Crackle commentedhi @andypost,
Improved the patch. please review
Comment #113
andypostOverall this looks mostly ready, except update hook and nitpick with extra empty lines
Needs work for update hook clean-up
this looks totally wrong
1) this should be one update hook
2) this should just set to FALSE default setting for existing installs (getEditable, set FALSE, save)
for new installs provided config file will be installed automatically
no need in extra empty lines
Comment #114
harsha012 CreditAttribution: harsha012 as a volunteer and at Red Crackle commentedimproved it. please check
Comment #115
harsha012 CreditAttribution: harsha012 as a volunteer and at Red Crackle commentedComment #116
andypostno need in this message
needs new lines
Comment #117
harsha012 CreditAttribution: harsha012 as a volunteer and at Red Crackle commented@andypost improved the patch as per comment #116
Comment #118
andypost@harsha012 thanx a lot! now it looks ready to go
Assigning to @greggles to commit/approve
Comment #119
pfrenssenI reviewed the patch and it looks really great. I found a few small nitpicks.
This use statement seems to be unused.
These two lines have 2 spaces before the '='.
The last line has two semicolons at the end.
It is recommended to use the shorthand array syntax '[]' instead of the longhand 'array()' for D8.
It's a good practice to type hint the
$form_state
onFormStateInterface
. Also since it is an object it is not needed to pass it by reference.Maybe update these user facing strings a bit. It's 'to log in' and not 'to login'.
Comment #120
pfrenssenFixed my nitpicks from #119. Leaving this on RTBC since this only changes coding standards and strings, not actual functionality.
Comment #121
pfrenssenThis part doesn't work yet.
$login_with_username
is always set, so the message about the 'e-mail or username' is always shown, even if the option is disabled.This should use
!empty()
instead ofisset()
.Comment #122
andypostnice catch, then test should be also improved
Comment #123
pfrenssenI'll give it a go, I have some free time now.
Comment #124
pfrenssenAdded the test and fixed the bug. I also ported the test to BrowserTestBase, it was just a matter of moving the test to correct location and changing the base class.
The additional test coverage also discovered a new small bug: if the login form was cached by the page cache, the cached version was not cleared when the Email Registration settings change. The old form would still be displayed until the next time a full cache clear occurs. I fixed this too.
There are a few ways that this can still be improved. It would be great to for example make the UI texts and error messages configurable. I consider this nice-to-haves though. They can be added later in follow ups.
Comment #126
JeroenTComment #127
JeroenTMarking as RTBC since remarks in #119 are fixed and the tests are improved.
Comment #128
andypostI just released next RC including #2825909: Password Reset Email Field Type
so patch maybe needs reroll, I think if everything went fine to release 1.0 and include this change to 1.1
there's suggestion to get rid of $this->container just can;t find core issue
Comment #129
andypostNeeds work because removes compatibility with early commited #2777701: Email registration module needs to do Profile validation prior to saving
looks we need migration path from d7 in follow-up
I think for new installs better to have this TRUE but for existing ones set to false in update hook
still not sure about removal
on one hand that should never happens otoh that code was added for reason in previous release #2777701: Email registration module needs to do Profile validation prior to saving
Comment #130
pfrenssenOK I didn't realize this. It appears a bug was fixed in that issue but there was no test added for it, and no documentation on why this is needed.
Comment #131
pfrenssenAre you sure about this? I think it is not the most common use case for websites to allow users to log in using either a username or e-mail address. OK, there are a lot of sites out there that do this, but the vast majority allow only to log in with e-mail address, or only to log in with username.
I think it's better to default to e-mail address only, I think that better fits with what people expect who install this module. The help texts are also easier to understand. Anyway this is not so important, it can be configured easily :)
The issue summary mentions "The documentation seems to imply that this is not the intended behavior but it seems like some people might want it." -> this means we also need to update the documentation in this issue.
Comment #132
JeroenTPatch attached.
Comment #133
JeroenTWhat's keeping us from committing this issue?
Remarks from #129 are answered and Follow-up issues are created.
Comment #134
franciscojlucero CreditAttribution: franciscojlucero as a volunteer commentedWorks as expected
Comment #135
andypostNow that looks totally ready for commit, gonna commit it this WE
to fix on commit, should be lowercase
Comment #137
andypostThanx everyone! finally commited