Skip to content
This repository was archived by the owner on Dec 25, 2024. It is now read-only.

Commit 9e0c300

Browse files
committed
Fixes inputs to RequestField
1 parent 80ddb7a commit 9e0c300

File tree

2 files changed

+6
-6
lines changed
  • modules/openapi-json-schema-generator/src/main/resources/python
  • samples/openapi3/client/petstore/python/src/petstore_api

2 files changed

+6
-6
lines changed

modules/openapi-json-schema-generator/src/main/resources/python/rest.hbs

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -25,9 +25,9 @@ class RequestField(fields.RequestField):
2525
self,
2626
name: str,
2727
data: _TYPE_FIELD_VALUE,
28-
filename: str | None = None,
29-
headers: typing.Mapping[str, typing.Union[str, None]] | None = None,
30-
header_formatter: typing.Callable[[str, _TYPE_FIELD_VALUE], str] | None = None,
28+
filename: typing.Optional[str] = None,
29+
headers: typing.Optional[typing.Mapping[str, typing.Union[str, None]]] = None,
30+
header_formatter: typing.Optional[typing.Callable[[str, _TYPE_FIELD_VALUE], str]] = None,
3131
):
3232
super().__init__(name, data, filename, headers, header_formatter) # type: ignore
3333

samples/openapi3/client/petstore/python/src/petstore_api/rest.py

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -30,9 +30,9 @@ def __init__(
3030
self,
3131
name: str,
3232
data: _TYPE_FIELD_VALUE,
33-
filename: str | None = None,
34-
headers: typing.Mapping[str, typing.Union[str, None]] | None = None,
35-
header_formatter: typing.Callable[[str, _TYPE_FIELD_VALUE], str] | None = None,
33+
filename: typing.Optional[str] = None,
34+
headers: typing.Optional[typing.Mapping[str, typing.Union[str, None]]] = None,
35+
header_formatter: typing.Optional[typing.Callable[[str, _TYPE_FIELD_VALUE], str]] = None,
3636
):
3737
super().__init__(name, data, filename, headers, header_formatter) # type: ignore
3838

0 commit comments

Comments
 (0)