34 $this->options->assertRequiredOptions( self::CONSTRUCTOR_OPTIONS );
56 if ( $change ===
'changed' ) {
57 $emailContent = $builder->buildNotificationEmailChanged( $recipientUser->
getName(), $newEmail );
59 $emailContent = $builder->buildNotificationEmailRemoved( $recipientUser->
getName() );
62 return $this->sendEmail(
65 $emailContent[
'subject'],
66 $emailContent[
'body'][
'text'],
67 $emailContent[
'body'][
'html']
71 $subject = $ctx->
msg(
'notificationemail_subject_' . $change )->text();
72 $bodyText = $ctx->
msg(
73 'notificationemail_body_' . $change,
79 return $this->sendEmail( $recipientUser, $ctx, $subject, $bodyText );
82 private function sendEmail(
87 ?
string $bodyHtml =
null
91 $ctx->msg(
'emailsender' )->inContentLanguage()->text()
94 return $this->emailer->send(
A class containing constants representing the names of configuration variables.
const AllowHTMLEmail
Name constant for the AllowHTMLEmail setting, for use with Config::get()
const PasswordSender
Name constant for the PasswordSender setting, for use with Config::get()
Generic operation result class Has warning/error list, boolean status and arbitrary value.
Interface for objects which can provide a MediaWiki context on request.