Closed (fixed)
Project:
Drupal core
Version:
9.2.x-dev
Component:
user.module
Priority:
Normal
Category:
Task
Assigned:
Unassigned
Reporter:
Created:
5 Dec 2020 at 21:33 UTC
Updated:
23 Dec 2020 at 13:44 UTC
Jump to comment: Most recent, Most recent file
Comments
Comment #2
g-brodieiFollowing for future deprecation work TODO.
Comment #3
ravi.shankar commentedTried to address this issue, please review.
Comment #5
jonathanshawThis is technically an internal API, but I suspect it should have a change record as it's ancient and useful and it's probably not uncommon for it to be called by custom code.
See change record
I think this should be "Specifying the notification language using the $langcode parameter is deprecated in drupal:9.2.0 and is removed from drupal:10.0.0. Omit the parameter. See https://..."
Comment #6
longwaveWe have a test fail presumably due to this:
So we still have one caller that sets $langcode - is this safe to simply remove?
Comment #7
longwaveAdded change record: https://www.drupal.org/node/3187082
Answering my own question in #6: yes, because the fallback is to the preferred langcode anyway.
Addressed #5 and #6 and added a deprecation test.
Comment #8
g-brodiei1. Tried the test and it does push the deprecation message into the deprecation collections.
2. Test will fail when @trigger_error was commented out.
3. The message in deprecation annotation block and @trigger_error are both clear and easy to understand.
4. Confirms the removal of $langcode in _user_mail_notify in UserAuthenticationController.php does fall back to preferred Langcode by default.
Ref:
https://www.drupal.org/about/core/policies/core-change-policies/drupal-c...
Comment #9
alexpottCommitted ab50d1b and pushed to 9.2.x. Thanks!