浏览代码

fixed user add

tags/0.1.0^0
Robin Thoni 8 年前
父节点
当前提交
03ff6c7334
共有 1 个文件被更改,包括 1 次插入1 次删除
  1. 1
    1
      src/Auth/Business/LuticateUsersBusiness.php

+ 1
- 1
src/Auth/Business/LuticateUsersBusiness.php 查看文件

@@ -137,7 +137,7 @@ class LuticateUsersBusiness extends LuBusiness {
137 137
         $hash = self::hashPassword($password);
138 138
         if (filter_var($username, FILTER_VALIDATE_EMAIL))
139 139
             self::badInput("Username can not be an email");
140
-        if (!preg_match("/^[A-Za-z0-9\\-_\\.]$/", $username)) {
140
+        if (!preg_match("/^[A-Za-z0-9\\-_\\.]+$/", $username)) {
141 141
             self::badInput("Username can only contain letters (A-Z a-z), numbers (0-9), hyphen (-), underscore (_) and dot (.)");
142 142
         }
143 143
         if (!filter_var($email, FILTER_VALIDATE_EMAIL))

正在加载...
取消
保存