Skip to content

Commit

Permalink
bug: set circular reference counter #199
Browse files Browse the repository at this point in the history
  • Loading branch information
srinandan committed May 9, 2023
1 parent 4340f38 commit dc35055
Showing 1 changed file with 4 additions and 1 deletion.
5 changes: 4 additions & 1 deletion internal/bundlegen/generateapi.go
Original file line number Diff line number Diff line change
Expand Up @@ -115,7 +115,7 @@ func LoadDocumentFromFile(filePath string, validate bool, formatValidation bool)
var jsonContent []byte

// see ./test/circular-reference.json and https://github.com/apigee/apigeecli/issues/199
openapi3.CircularReferenceCounter = 10
openapi3.CircularReferenceCounter = 20

doc, err = openapi3.NewLoader().LoadFromFile(filePath)
if err != nil {
Expand Down Expand Up @@ -162,6 +162,9 @@ func LoadDocumentFromURI(uri string, validate bool, formatValidation bool) (stri
return "", nil, err
}

// see ./test/circular-reference.json and https://github.com/apigee/apigeecli/issues/199
openapi3.CircularReferenceCounter = 20

doc, err = openapi3.NewLoader().LoadFromURI(u)
if err != nil {
return "", nil, err
Expand Down

0 comments on commit dc35055

Please sign in to comment.