Skip to content
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
7 changes: 4 additions & 3 deletions mixin.go
Original file line number Diff line number Diff line change
Expand Up @@ -130,6 +130,7 @@ func pathItemOps(p spec.PathItem) []*spec.Operation {
rv = appendOp(rv, p.Post)
rv = appendOp(rv, p.Delete)
rv = appendOp(rv, p.Head)
rv = appendOp(rv, p.Options)
rv = appendOp(rv, p.Patch)

return rv
Expand Down Expand Up @@ -213,9 +214,9 @@ func mergePaths(primary *spec.Swagger, m *spec.Swagger, opIDs map[string]bool, m
// Swagger requires that operationIds be
// unique within a spec. If we find a
// collision we append "Mixin0" to the
// operatoinId we are adding, where 0 is mixin
// operationId we are adding, where 0 is mixin
// index. We assume that operationIds with
// all the proivded specs are already unique.
// all the provided specs are already unique.
piops := pathItemOps(v)
for _, piop := range piops {
if opIDs[piop.ID] {
Expand Down Expand Up @@ -358,7 +359,7 @@ func mergeSwaggerProps(primary *spec.Swagger, m *spec.Swagger) []string {

if primary.ExternalDocs == nil {
primary.ExternalDocs = m.ExternalDocs
} else if m != nil {
} else if m.ExternalDocs != nil {
skippedDocs = mergeExternalDocs(primary.ExternalDocs, m.ExternalDocs)
skipped = append(skipped, skippedDocs...)
}
Expand Down
Loading