Bump version to 0.7.1

This commit is contained in:
Daniel Supernault 2018-12-23 17:16:59 -07:00
parent 476e9ff8b3
commit e39f88f6c6
No known key found for this signature in database
GPG key ID: 0DEF1C662C9033F7
3 changed files with 115 additions and 2 deletions

View file

@ -55,7 +55,6 @@ class RegisterController extends Controller
$this->validateUsername($data['username']);
$usernameRules = [
'required',
'alpha_dash',
'min:2',
'max:15',
'unique:users',
@ -63,6 +62,10 @@ class RegisterController extends Controller
if (!ctype_alpha($value[0])) {
return $fail($attribute.' is invalid. Username must be alpha-numeric and start with a letter.');
}
$val = str_replace(['-', '_'], '', $value);
if(!ctype_alnum($val)) {
return $fail($attribute . ' is invalid. Username must be alpha-numeric.');
}
},
];