Skip to content

Commit

Permalink
[ADD] Support new APIRoute Fields
Browse files Browse the repository at this point in the history
  • Loading branch information
acwazz committed Aug 4, 2022
1 parent 18d6a5a commit 393cbc4
Show file tree
Hide file tree
Showing 4 changed files with 7 additions and 5 deletions.
2 changes: 1 addition & 1 deletion fastapi_responseschema/__init__.py
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@
from .helpers import wrap_app_responses, wrap_error_responses


__version__ = '1.1.0'
__version__ = '1.2.0'


__all__ = [
Expand Down
6 changes: 4 additions & 2 deletions fastapi_responseschema/routing.py
Original file line number Diff line number Diff line change
Expand Up @@ -148,7 +148,8 @@ def __init__(
include_in_schema: bool = True,
response_class: Optional[Type[Response]] = None,
dependency_overrides_provider: Optional[Any] = None,
callbacks: Optional[List["APIRoute"]] = None
callbacks: Optional[List["APIRoute"]] = None,
**kwargs: Any
) -> None:
if response_model: # If a `response_model` is set, then wrap the `response_model` with a response schema
WrapperModel = self.get_wrapper_model(is_error=self.is_error_state(status_code=status_code), response_model=response_model)
Expand Down Expand Up @@ -200,7 +201,8 @@ def __init__(
include_in_schema=include_in_schema,
response_class=response_class,
dependency_overrides_provider=dependency_overrides_provider,
callbacks=callbacks
callbacks=callbacks,
**kwargs
)


Expand Down
2 changes: 1 addition & 1 deletion pyproject.toml
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
[tool.poetry]
name = "fastapi-responseschema"
version = "1.1.0"
version = "1.2.0"
description = "Generic and common response schemas for FastAPI"
authors = ["Emanuele Addis <[email protected]>"]
license = "MIT"
Expand Down
2 changes: 1 addition & 1 deletion tests/test_fastapi_responseschema.py
Original file line number Diff line number Diff line change
Expand Up @@ -2,4 +2,4 @@


def test_version():
assert __version__ == '1.1.0'
assert __version__ == '1.2.0'

0 comments on commit 393cbc4

Please sign in to comment.