Skip to content

Commit

Permalink
fix: change parameter to snake_case
Browse files Browse the repository at this point in the history
  • Loading branch information
barabobBOB committed Dec 15, 2023
1 parent 53bcf85 commit db3b83b
Show file tree
Hide file tree
Showing 4 changed files with 5 additions and 5 deletions.
4 changes: 2 additions & 2 deletions cmd/server/handler/sos_post_handler.go
Original file line number Diff line number Diff line change
Expand Up @@ -69,15 +69,15 @@ func (h *SosPostHandler) WriteSosPost(w http.ResponseWriter, r *http.Request) {
// @Tags posts
// @Accept json
// @Produce json
// @Param authorID query int false "작성자 ID"
// @Param author_id query int false "작성자 ID"
// @Param page query int false "페이지 번호" default(1)
// @Param size query int false "페이지 사이즈" default(20)
// @Param sort_by query string false "정렬 기준" Enums(newest, deadline)
// @Security FirebaseAuth
// @Success 200 {object} commonviews.PaginatedView[sos_post.FindSosPostResponse]
// @Router /posts/sos [get]
func (h *SosPostHandler) FindSosPosts(w http.ResponseWriter, r *http.Request) {
authorIDQuery := r.URL.Query().Get("authorID")
authorIDQuery := r.URL.Query().Get("author_id")
pageQuery := r.URL.Query().Get("page")
sizeQuery := r.URL.Query().Get("size")
sortByQuery := r.URL.Query().Get("sort_by")
Expand Down
2 changes: 1 addition & 1 deletion pkg/docs/docs.go
Original file line number Diff line number Diff line change
Expand Up @@ -181,7 +181,7 @@ const docTemplate = `{
{
"type": "integer",
"description": "작성자 ID",
"name": "authorID",
"name": "author_id",
"in": "query"
},
{
Expand Down
2 changes: 1 addition & 1 deletion pkg/docs/swagger.json
Original file line number Diff line number Diff line change
Expand Up @@ -174,7 +174,7 @@
{
"type": "integer",
"description": "작성자 ID",
"name": "authorID",
"name": "author_id",
"in": "query"
},
{
Expand Down
2 changes: 1 addition & 1 deletion pkg/docs/swagger.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -609,7 +609,7 @@ paths:
parameters:
- description: 작성자 ID
in: query
name: authorID
name: author_id
type: integer
- default: 1
description: 페이지 번호
Expand Down

0 comments on commit db3b83b

Please sign in to comment.