Skip to content

Commit df87cbd

Browse files
committed
fix two last mypy errors
1 parent 1ff010c commit df87cbd

File tree

2 files changed

+3
-2
lines changed

2 files changed

+3
-2
lines changed

openlibrary/asgi_app.py

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -118,7 +118,7 @@ async def i18n_middleware(request: Request, call_next):
118118
sentry: Sentry | None = None
119119

120120

121-
def create_app() -> FastAPI:
121+
def create_app() -> FastAPI | None:
122122
if "pytest" not in sys.modules:
123123
_setup_env()
124124

@@ -133,7 +133,7 @@ def create_app() -> FastAPI:
133133

134134
global sentry
135135
if sentry is not None:
136-
return
136+
return None
137137
sentry = init_sentry(getattr(infogami.config, 'sentry', {}))
138138
set_tag("fastapi", True)
139139

openlibrary/fastapi/account.py

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -92,6 +92,7 @@ async def check_authentication(
9292
user_key=user.user_key if user else None,
9393
timestamp=user.timestamp if user else None,
9494
is_authenticated=user is not None,
95+
error=None,
9596
cookie_name=cookie_name,
9697
cookie_value=(
9798
cookie_value[:50] + "..."

0 commit comments

Comments
 (0)