Movatterモバイル変換


[0]ホーム

URL:


Skip to content

Navigation Menu

Sign in
Appearance settings

Search code, repositories, users, issues, pull requests...

Provide feedback

We read every piece of feedback, and take your input very seriously.

Saved searches

Use saved searches to filter your results more quickly

Sign up
Appearance settings

Commitb8c9192

Browse files
authored
fix: generalize password invalid message (#19307)
fixes#19044 password over 64 characters means it's _too_ strong; now the errormessage is applicable to this case
1 parent94bf1e3 commitb8c9192

File tree

1 file changed

+2
-2
lines changed

1 file changed

+2
-2
lines changed

‎coderd/users.go‎

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -148,7 +148,7 @@ func (api *API) postFirstUser(rw http.ResponseWriter, r *http.Request) {
148148
err=userpassword.Validate(createUser.Password)
149149
iferr!=nil {
150150
httpapi.Write(ctx,rw,http.StatusBadRequest, codersdk.Response{
151-
Message:"Passwordnot strong enough!",
151+
Message:"Passwordis invalid",
152152
Validations: []codersdk.ValidationError{{
153153
Field:"password",
154154
Detail:err.Error(),
@@ -448,7 +448,7 @@ func (api *API) postUser(rw http.ResponseWriter, r *http.Request) {
448448
err=userpassword.Validate(req.Password)
449449
iferr!=nil {
450450
httpapi.Write(ctx,rw,http.StatusBadRequest, codersdk.Response{
451-
Message:"Passwordnot strong enough!",
451+
Message:"Passwordis invalid",
452452
Validations: []codersdk.ValidationError{{
453453
Field:"password",
454454
Detail:err.Error(),

0 commit comments

Comments
 (0)

[8]ページ先頭

©2009-2025 Movatter.jp