summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--install.php7
1 files changed, 5 insertions, 2 deletions
diff --git a/install.php b/install.php
index 243b319b4..7b1608b7a 100644
--- a/install.php
+++ b/install.php
@@ -212,10 +212,13 @@ function print_retry() {
*
* @author Andreas Gohr
*/
-function check_data($d){
+function check_data(&$d){
global $lang;
global $error;
+ //autolowercase the username
+ $d['superuser'] = strtolower($d['superuser']);
+
$ok = true;
// check input
@@ -240,7 +243,7 @@ function check_data($d){
$error[] = sprintf($lang['i_badval'],$lang['fullname']);
$ok = false;
}
- if(empty($d['email']) || strstr($d['fullname'],':')){
+ if(empty($d['email']) || strstr($d['email'],':') || !strstr($d['email'],'@')){
$error[] = sprintf($lang['i_badval'],$lang['email']);
$ok = false;
}