File tree Expand file tree Collapse file tree 1 file changed +5
-7
lines changed
Expand file tree Collapse file tree 1 file changed +5
-7
lines changed Original file line number Diff line number Diff line change @@ -575,6 +575,11 @@ func generateSchema(t reflect.Type) map[string]interface{} {
575575 continue
576576 }
577577
578+ // Skip fields that are path or query parameters - they are handled separately
579+ if field .Tag .Get ("path" ) != "" || field .Tag .Get ("query" ) != "" {
580+ continue
581+ }
582+
578583 // Get JSON tag name
579584 jsonTag := field .Tag .Get ("json" )
580585 if jsonTag == "-" {
@@ -602,13 +607,6 @@ func generateSchema(t reflect.Type) map[string]interface{} {
602607 }
603608 }
604609
605- // Add description from path/query tags
606- if pathTag := field .Tag .Get ("path" ); pathTag != "" {
607- fieldSchema ["description" ] = "Path parameter: " + pathTag
608- } else if queryTag := field .Tag .Get ("query" ); queryTag != "" {
609- fieldSchema ["description" ] = "Query parameter: " + queryTag
610- }
611-
612610 properties [fieldName ] = fieldSchema
613611 }
614612
You can’t perform that action at this time.
0 commit comments