Skip to content

Commit

Permalink
中文用户名注册&补全翻译
Browse files Browse the repository at this point in the history
  • Loading branch information
houzhenhong committed Oct 30, 2016
1 parent a591d4d commit 1ce5cdf
Show file tree
Hide file tree
Showing 2 changed files with 2 additions and 2 deletions.
2 changes: 1 addition & 1 deletion vendor/flarum/core/src/Core/Validator/UserValidator.php
Original file line number Diff line number Diff line change
Expand Up @@ -45,7 +45,7 @@ protected function getRules()
return [
'username' => [
'required',
'regex:/^[a-z0-9_-]+$/i',
'regex:/^[-_a-zA-Z0-9\x7f-\xff]+$/i',
'unique:users,username'.$idSuffix,
'min:3',
'max:30'
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -374,7 +374,7 @@ core:

# These translations are used in unverified user alert box.
user_email_confirmation:
alert_message: core.ref.confirmation_email_sent
alert_message: => core.ref.confirmation_email_sent
resend_button: 重新发送确认邮件
sent_message: 发送

Expand Down

2 comments on commit 1ce5cdf

@nandust
Copy link

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

我按照你这样设置了还是不能中文名注册

@skywalker512
Copy link
Owner

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

非常抱歉没有进行测试就发布,请暂时关闭ReFlar/user-management插件。
此插件重写了注册代码,正在寻找解决方案。

Please sign in to comment.