Improve the maintainblity of the reserved username list (#32229)

(cherry picked from commit 6029d78ab5006e8fb4f42adb5a8c491f19fa7b0a)

Conflicts:
  models/user/user.go
	services/user/user_test.go
    trivial context conflict
	tests/integration/user_test.go
    discarded entirely because dot may be allowed in Forgejo under
    some conditions
This commit is contained in:
Earl Warren 2024-10-13 10:13:04 +03:00
parent eff28911d3
commit 7855e4bb56
No known key found for this signature in database
GPG key ID: 0579CB2928A78A00
3 changed files with 39 additions and 46 deletions

View file

@ -114,10 +114,7 @@ func TestRenameReservedUsername(t *testing.T) {
"avatar",
"avatars",
"captcha",
"commits",
"debug",
"devtest",
"error",
"explore",
"favicon.ico",
"ghost",
@ -126,16 +123,12 @@ func TestRenameReservedUsername(t *testing.T) {
"manifest.json",
"metrics",
"milestones",
"new",
"notifications",
"org",
"pulls",
"raw",
"repo",
"repo-avatars",
"robots.txt",
"search",
"serviceworker.js",
"ssh_info",
"swagger.v1.json",
"user",