summaryrefslogtreecommitdiffstats
path: root/routers/api/v1/repo/repo.go
diff options
context:
space:
mode:
Diffstat (limited to 'routers/api/v1/repo/repo.go')
-rw-r--r--routers/api/v1/repo/repo.go2
1 files changed, 1 insertions, 1 deletions
diff --git a/routers/api/v1/repo/repo.go b/routers/api/v1/repo/repo.go
index fb1472226f..d222c9b080 100644
--- a/routers/api/v1/repo/repo.go
+++ b/routers/api/v1/repo/repo.go
@@ -135,7 +135,7 @@ func Search(ctx *context.APIContext) {
opts := &models.SearchRepoOptions{
ListOptions: utils.GetListOptions(ctx),
Actor: ctx.User,
- Keyword: strings.Trim(ctx.FormString("q"), " "),
+ Keyword: ctx.FormTrim("q"),
OwnerID: ctx.FormInt64("uid"),
PriorityOwnerID: ctx.FormInt64("priority_owner_id"),
TeamID: ctx.FormInt64("team_id"),