1 user.install user_update_1017()

Add admin mail text for pending approval.

Related topics

File

core/modules/user/user.install, line 1238
Install, update and uninstall functions for the user module.

Code

function user_update_1017() {
  $config = config('user.mail');
  $translatables = $config->get('_config_translatables');
  $translatables[] = 'register_pending_approval_admin_body';
  $translatables[] = 'register_pending_approval_admin_subject';
  $config->set('_config_translatables', $translatables);
  $config->set('register_pending_approval_admin_body', "[user:name] has applied for an account.\n\n[user:edit-url]");
  $config->set('register_pending_approval_admin_subject', 'New account of [user:name] at [site:name] (pending approval)');
  $config->save();
}