Skip to content

Commit

Permalink
show summary if any comment is present
Browse files Browse the repository at this point in the history
  • Loading branch information
LukasJenicek committed Mar 6, 2024
1 parent 4829514 commit a5e4112
Showing 1 changed file with 3 additions and 0 deletions.
3 changes: 3 additions & 0 deletions main.go.tmpl
Original file line number Diff line number Diff line change
Expand Up @@ -128,6 +128,9 @@ paths:
{{- range $_, $method := .Methods}}
/rpc/{{$service.Name}}/{{$method.Name}}:
post:
{{- if gt (len $method.Comments) 0 }}
summary: '{{ join $method.Comments "\n" }}'
{{- end }}
requestBody:
content:
application/json:
Expand Down

0 comments on commit a5e4112

Please sign in to comment.