|
@@ -142,14 +142,8 @@ class Auth |
|
@@ -142,14 +142,8 @@ class Auth |
142
|
$this->setError('Nickname already exist');
|
142
|
$this->setError('Nickname already exist');
|
143
|
return false;
|
143
|
return false;
|
144
|
}
|
144
|
}
|
145
|
- if ($email && User::getByEmail($email)) {
|
|
|
146
|
- $this->setError('Email already exist');
|
|
|
147
|
- return false;
|
|
|
148
|
- }
|
|
|
149
|
- if ($mobile && User::getByMobile($mobile)) {
|
|
|
150
|
- $this->setError('Mobile already exist');
|
|
|
151
|
- return false;
|
|
|
152
|
- }
|
145
|
+
|
|
|
146
|
+
|
153
|
|
147
|
|
154
|
$ip = request()->ip();
|
148
|
$ip = request()->ip();
|
155
|
$time = time();
|
149
|
$time = time();
|
|
@@ -163,6 +157,8 @@ class Auth |
|
@@ -163,6 +157,8 @@ class Auth |
163
|
'score' => 0,
|
157
|
'score' => 0,
|
164
|
'avatar' => '',
|
158
|
'avatar' => '',
|
165
|
];
|
159
|
];
|
|
|
160
|
+ print_r($data);return;
|
|
|
161
|
+
|
166
|
$params = array_merge($data, [
|
162
|
$params = array_merge($data, [
|
167
|
'nickname' => preg_match("/^1[3-9]{1}\d{9}$/", $username) ? substr_replace($username, '****', 3, 4) : $username,
|
163
|
'nickname' => preg_match("/^1[3-9]{1}\d{9}$/", $username) ? substr_replace($username, '****', 3, 4) : $username,
|
168
|
'salt' => Random::alnum(),
|
164
|
'salt' => Random::alnum(),
|