Skip to content

Commit

Permalink
protoc-gen-swagger: Update internal mapping for boolean type (#1466) (#…
Browse files Browse the repository at this point in the history
…1470)

Fixes #1463
  • Loading branch information
ozraza authored Jun 18, 2020
1 parent c514f90 commit 6a46397
Show file tree
Hide file tree
Showing 3 changed files with 3 additions and 8 deletions.
9 changes: 3 additions & 6 deletions examples/internal/proto/examplepb/wrappers.swagger.json
Original file line number Diff line number Diff line change
Expand Up @@ -50,8 +50,7 @@
"200": {
"description": "A successful response.",
"schema": {
"type": "boolean",
"format": "boolean"
"type": "boolean"
}
},
"default": {
Expand All @@ -67,8 +66,7 @@
"in": "body",
"required": true,
"schema": {
"type": "boolean",
"format": "boolean"
"type": "boolean"
}
}
],
Expand Down Expand Up @@ -404,8 +402,7 @@
"format": "double"
},
"boolValue": {
"type": "boolean",
"format": "boolean"
"type": "boolean"
},
"uint32Value": {
"type": "integer",
Expand Down
1 change: 0 additions & 1 deletion protoc-gen-openapiv2/internal/genopenapi/template.go
Original file line number Diff line number Diff line change
Expand Up @@ -65,7 +65,6 @@ var wktSchemas = map[string]schemaCore{
},
".google.protobuf.BoolValue": {
Type: "boolean",
Format: "boolean",
},
".google.protobuf.Empty": {},
".google.protobuf.Struct": {
Expand Down
1 change: 0 additions & 1 deletion protoc-gen-openapiv2/internal/genopenapi/template_test.go
Original file line number Diff line number Diff line change
Expand Up @@ -2111,7 +2111,6 @@ func TestSchemaOfField(t *testing.T) {
refs: make(refMap),
expected: schemaCore{
Type: "boolean",
Format: "boolean",
},
},
{
Expand Down

0 comments on commit 6a46397

Please sign in to comment.