mirror of
https://github.com/usememos/memos.git
synced 2025-10-29 07:48:14 +08:00
chore: update username regexp
This commit is contained in:
parent
cfc5599334
commit
c58820fa64
2 changed files with 2 additions and 2 deletions
|
|
@ -22,7 +22,7 @@ import (
|
|||
)
|
||||
|
||||
var (
|
||||
usernameMatcher = regexp.MustCompile("^[a-z]([a-z0-9-]{1,30}[a-z0-9])?$")
|
||||
usernameMatcher = regexp.MustCompile("^[a-z0-9]([a-z0-9-]{1,30}[a-z0-9])$")
|
||||
)
|
||||
|
||||
type SignIn struct {
|
||||
|
|
|
|||
|
|
@ -23,7 +23,7 @@ import (
|
|||
)
|
||||
|
||||
var (
|
||||
usernameMatcher = regexp.MustCompile("^[a-z]([a-z0-9-]{1,30}[a-z0-9])?$")
|
||||
usernameMatcher = regexp.MustCompile("^[a-z0-9]([a-z0-9-]{1,30}[a-z0-9])$")
|
||||
)
|
||||
|
||||
type UserService struct {
|
||||
|
|
|
|||
Loading…
Add table
Reference in a new issue