summaryrefslogtreecommitdiff
path: root/includes/specials/SpecialEmailuser.php
diff options
context:
space:
mode:
Diffstat (limited to 'includes/specials/SpecialEmailuser.php')
-rw-r--r--includes/specials/SpecialEmailuser.php13
1 files changed, 9 insertions, 4 deletions
diff --git a/includes/specials/SpecialEmailuser.php b/includes/specials/SpecialEmailuser.php
index 4d875e6e..b5ad589e 100644
--- a/includes/specials/SpecialEmailuser.php
+++ b/includes/specials/SpecialEmailuser.php
@@ -139,7 +139,8 @@ class SpecialEmailUser extends UnlistedSpecialPage {
$this->mTargetObj = $ret;
$form = new HTMLForm( $this->getFormFields(), $this->getContext() );
- $form->addPreText( $this->msg( 'emailpagetext' )->parse() );
+ // By now we are supposed to be sure that $this->mTarget is a user name
+ $form->addPreText( $this->msg( 'emailpagetext', $this->mTarget )->parse() );
$form->setSubmitTextMsg( 'emailsend' );
$form->setTitle( $this->getTitle() );
$form->setSubmitCallback( array( __CLASS__, 'uiSubmit' ) );
@@ -162,7 +163,7 @@ class SpecialEmailUser extends UnlistedSpecialPage {
/**
* Validate target User
*
- * @param $target String: target user name
+ * @param string $target target user name
* @return User object on success or a string on error
*/
public static function getTarget( $target ) {
@@ -190,7 +191,7 @@ class SpecialEmailUser extends UnlistedSpecialPage {
* Check whether a user is allowed to send email
*
* @param $user User object
- * @param $editToken String: edit token
+ * @param string $editToken edit token
* @return null on success or string on error
*/
public static function getPermissionsError( $user, $editToken ) {
@@ -230,7 +231,7 @@ class SpecialEmailUser extends UnlistedSpecialPage {
/**
* Form to ask for target user name.
*
- * @param $name String: user name submitted.
+ * @param string $name user name submitted.
* @return String: form asking for user name.
*/
protected function userForm( $name ) {
@@ -336,4 +337,8 @@ class SpecialEmailUser extends UnlistedSpecialPage {
return $status;
}
}
+
+ protected function getGroupName() {
+ return 'users';
+ }
}