Skip to content

Commit

Permalink
ci: apply sourcery (#2412)
Browse files Browse the repository at this point in the history
Co-authored-by: Cody Fincher <[email protected]>
  • Loading branch information
JacobCoffee and cofin authored Oct 7, 2023
1 parent da2a0f2 commit 628a094
Show file tree
Hide file tree
Showing 2 changed files with 2 additions and 2 deletions.
2 changes: 1 addition & 1 deletion litestar/app.py
Original file line number Diff line number Diff line change
Expand Up @@ -479,7 +479,7 @@ def _get_default_plugins(plugins: list[PluginProtocol] | None = None) -> list[Pl
plugins.append(PydanticPlugin())
elif not pydantic_plugin_found and pydantic_init_plugin_found and not pydantic_schema_plugin_found:
plugins.append(PydanticSchemaPlugin())
elif not pydantic_plugin_found and not pydantic_init_plugin_found and pydantic_schema_plugin_found:
elif not pydantic_plugin_found and not pydantic_init_plugin_found:
plugins.append(PydanticInitPlugin())
with suppress(MissingDependencyException):
from litestar.contrib.attrs import AttrsSchemaPlugin
Expand Down
2 changes: 1 addition & 1 deletion litestar/contrib/minijnja.py
Original file line number Diff line number Diff line change
Expand Up @@ -91,7 +91,7 @@ def _loader(name: str) -> str:
Raises:
TemplateNotFoundException: if no template is found.
"""
directories = [directory] if not isinstance(directory, list) else directory
directories = directory if isinstance(directory, list) else [directory]

for d in directories:
template_path = Path(d) / name # pyright: ignore[reportGeneralTypeIssues]
Expand Down

0 comments on commit 628a094

Please sign in to comment.