mirror of
https://github.com/fastapi-users/fastapi-users.git
synced 2025-08-15 11:11:16 +08:00
Fix get_oauth_associate_router import to make it optional
This commit is contained in:
@ -13,12 +13,12 @@ from fastapi_users.router import (
|
||||
get_users_router,
|
||||
get_verify_router,
|
||||
)
|
||||
from fastapi_users.router.oauth import get_oauth_associate_router
|
||||
|
||||
try:
|
||||
from httpx_oauth.oauth2 import BaseOAuth2
|
||||
|
||||
from fastapi_users.router import get_oauth_router
|
||||
from fastapi_users.router.oauth import get_oauth_associate_router
|
||||
except ModuleNotFoundError: # pragma: no cover
|
||||
BaseOAuth2 = Type # type: ignore
|
||||
|
||||
|
Reference in New Issue
Block a user