Problem/Motivation
_user_mail_notify() is an internal, underscore-prefixed function. Still it is widely used in contrib and likely in custom modules. Some research in #3539178-27: Extract _user_mail_notify() into a user NotificationHandler turned out a non-exhaustive list of modules which for various reasons create an account and then send a registration mail.
Some modules dealing with user registration:
- https://www.drupal.org/project/better_register
- https://www.drupal.org/project/bulk_user_registration
- https://www.drupal.org/project/business_core
- https://www.drupal.org/project/cas
- https://www.drupal.org/project/civicrm_entity
- https://www.drupal.org/project/cognito
- https://www.drupal.org/project/commerce
- https://www.drupal.org/project/commerce_guest_registration
- https://www.drupal.org/project/created_account_register_message
- https://www.drupal.org/project/crowd
- https://www.drupal.org/project/entrasync
- https://www.drupal.org/project/firebase_authentication
- https://www.drupal.org/project/iyo
- https://www.drupal.org/project/jsonapi_user_resources
- https://www.drupal.org/project/minimal_register
- https://www.drupal.org/project/nodehive_core
- https://www.drupal.org/project/openlucius
- https://www.drupal.org/project/opigno_learning_path
- https://www.drupal.org/project/resend_register_mail
- https://www.drupal.org/project/resend_user_login_link_user_operation
- https://www.drupal.org/project/social_auth_hid
- https://www.drupal.org/project/user_csv_import
- https://www.drupal.org/project/webauthn
- https://www.drupal.org/project/webform_user_registration
Steps to reproduce
Proposed resolution
Expose a public API for registering a user. A call to this API should result in a user being created and an appropriate email sent out.
Deprecate the register* ops of _user_mail_notify().
Remaining tasks
User interface changes
Introduced terminology
API changes
Data model changes
Release notes snippet
Issue fork drupal-3540702
Show commands
Start within a Git clone of the project using the version control instructions.
Or, if you do not have SSH keys set up on git.drupalcode.org:
Comments
Comment #4
znerol commentedPostponed on #3578758: Investigate calls to _user_mail_notify() to identify missing API surface.