diff --git a/backend/app/http/posts.go b/backend/app/http/posts.go index 60ac8d3..52ca823 100644 --- a/backend/app/http/posts.go +++ b/backend/app/http/posts.go @@ -9,7 +9,7 @@ import ( ) type ListQuery struct { - keyword *string `query:"keyword"` + Keyword *string `query:"keyword"` } // @provider @@ -20,7 +20,7 @@ type posts struct{} // @Bind pagination query // @Bind query query func (ctl *posts) List(ctx fiber.Ctx, pagination *requests.Pagination, query *ListQuery) (*requests.Pager, error) { - cond := models.Posts.BuildConditionWithKey(query.keyword) + cond := models.Posts.BuildConditionWithKey(query.Keyword) return models.Posts.List(ctx.Context(), pagination, cond) }