Skip to content

Commit a009075

Browse files
committed
Revert type annotation to satisfy type valiation in test function
1 parent 790d0ba commit a009075

1 file changed

Lines changed: 2 additions & 2 deletions

File tree

src/routers/dependencies.py

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
from collections.abc import AsyncIterator
1+
from collections.abc import AsyncGenerator, AsyncIterator
22
from typing import Annotated
33

44
from fastapi import Depends
@@ -26,7 +26,7 @@ async def userdb_connection() -> AsyncIterator[AsyncConnection]:
2626
async def fetch_user(
2727
api_key: APIKey | None = None,
2828
user_data: Annotated[AsyncConnection | None, Depends(userdb_connection)] = None,
29-
) -> AsyncIterator[User | None]:
29+
) -> AsyncGenerator[User | None]:
3030
if not (api_key and user_data):
3131
yield None
3232
return

0 commit comments

Comments
 (0)