()
| 75 | |
| 76 | @lru_cache |
| 77 | def get_google_oauth_client() -> OAuth: |
| 78 | settings = get_settings() |
| 79 | if not settings.google_client_id or not settings.google_client_secret: |
| 80 | return None |
| 81 | |
| 82 | oauth = OAuth() |
| 83 | oauth.register( |
| 84 | "google", |
| 85 | client_id=settings.google_client_id, |
| 86 | client_secret=settings.google_client_secret, |
| 87 | server_metadata_url="https://accounts.google.com/.well-known/openid-configuration", |
| 88 | client_kwargs={"scope": "openid email profile"}, |
| 89 | ) |
| 90 | return oauth |
| 91 | |
| 92 | |
| 93 | async def get_google_user_info(oauth_client: OAuth, token: dict) -> dict | None: |
nothing calls this directly
no test coverage detected