summaryrefslogtreecommitdiff
path: root/actions
diff options
context:
space:
mode:
Diffstat (limited to 'actions')
-rw-r--r--actions/finishopenidlogin.php4
-rw-r--r--actions/profilesettings.php2
-rw-r--r--actions/updateprofile.php2
-rw-r--r--actions/userauthorization.php2
4 files changed, 5 insertions, 5 deletions
diff --git a/actions/finishopenidlogin.php b/actions/finishopenidlogin.php
index ff0b35218..ba1e933e3 100644
--- a/actions/finishopenidlogin.php
+++ b/actions/finishopenidlogin.php
@@ -217,7 +217,7 @@ class FinishopenidloginAction extends Action
if (!Validate::string($nickname, array('min_length' => 1,
'max_length' => 64,
- 'format' => VALIDATE_NUM . VALIDATE_ALPHA_LOWER))) {
+ 'format' => NICKNAME_FMT))) {
$this->showForm(_('Nickname must have only lowercase letters and numbers and no spaces.'));
return;
}
@@ -389,7 +389,7 @@ class FinishopenidloginAction extends Action
{
if (!Validate::string($str, array('min_length' => 1,
'max_length' => 64,
- 'format' => VALIDATE_NUM . VALIDATE_ALPHA_LOWER))) {
+ 'format' => NICKNAME_FMT))) {
return false;
}
if (!User::allowed_nickname($str)) {
diff --git a/actions/profilesettings.php b/actions/profilesettings.php
index fb847680b..d8fb2c9bb 100644
--- a/actions/profilesettings.php
+++ b/actions/profilesettings.php
@@ -189,7 +189,7 @@ class ProfilesettingsAction extends AccountSettingsAction
// Some validation
if (!Validate::string($nickname, array('min_length' => 1,
'max_length' => 64,
- 'format' => VALIDATE_NUM . VALIDATE_ALPHA_LOWER))) {
+ 'format' => NICKNAME_FMT))) {
$this->showForm(_('Nickname must have only lowercase letters and numbers and no spaces.'));
return;
} else if (!User::allowed_nickname($nickname)) {
diff --git a/actions/updateprofile.php b/actions/updateprofile.php
index d8b62fb09..f6cb277aa 100644
--- a/actions/updateprofile.php
+++ b/actions/updateprofile.php
@@ -79,7 +79,7 @@ class UpdateprofileAction extends Action
$nickname = $req->get_parameter('omb_listenee_nickname');
if ($nickname && !Validate::string($nickname, array('min_length' => 1,
'max_length' => 64,
- 'format' => VALIDATE_NUM . VALIDATE_ALPHA_LOWER))) {
+ 'format' => NICKNAME_FMT))) {
$this->clientError(_('Nickname must have only lowercase letters and numbers and no spaces.'));
return false;
}
diff --git a/actions/userauthorization.php b/actions/userauthorization.php
index 8dc2c808d..00903ae01 100644
--- a/actions/userauthorization.php
+++ b/actions/userauthorization.php
@@ -481,7 +481,7 @@ class UserauthorizationAction extends Action
$nickname = $_GET['omb_listenee_nickname'];
if (!Validate::string($nickname, array('min_length' => 1,
'max_length' => 64,
- 'format' => VALIDATE_NUM . VALIDATE_ALPHA_LOWER))) {
+ 'format' => NICKNAME_FMT))) {
throw new OAuthException('Nickname must have only letters and numbers and no spaces.');
}
$profile = $_GET['omb_listenee_profile'];