]> source.dussan.org Git - gitea.git/commitdiff
fix: add search to reserved usernames (#9063)
authorAntoine GIRARD <sapk@users.noreply.github.com>
Mon, 18 Nov 2019 20:03:25 +0000 (21:03 +0100)
committertechknowlogick <techknowlogick@gitea.io>
Mon, 18 Nov 2019 20:03:25 +0000 (15:03 -0500)
* fix: add search to reserved usernames

* Update integrations/user_test.go

Co-Authored-By: 6543 <24977596+6543@users.noreply.github.com>
integrations/user_test.go
models/user.go

index 0a6fdd19d5a09b05fcf870b0b136c26b0b479c10..452ea2ddf0d94fa8cfbc1cafb1d973da3b4072f5 100644 (file)
@@ -90,6 +90,7 @@ func TestRenameReservedUsername(t *testing.T) {
                "repo",
                "template",
                "user",
+               "search",
        }
 
        session := loginUser(t, "user2")
index ce78e5bfcee90c5b1b4fd4e2b0eb9acb5922defa..2cef2e5decccec63f0f12e0997b31f7e936b571d 100644 (file)
@@ -822,6 +822,7 @@ var (
                ".",
                "..",
                ".well-known",
+               "search",
        }
        reservedUserPatterns = []string{"*.keys", "*.gpg"}
 )