chore(web): Remove spam "login page loaded" log (#552)

This commit is contained in:
Brendan Kellam 2025-10-06 15:04:41 -07:00 committed by GitHub
parent 623c794a75
commit 5e3e4f000a
No known key found for this signature in database
GPG key ID: B5690EEEBB952194
2 changed files with 3 additions and 5 deletions

View file

@ -7,6 +7,9 @@ and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0
## [Unreleased]
### Changed
- Remove spam "login page loaded" log. [#552](https://github.com/sourcebot-dev/sourcebot/pull/552)
### Added
- Added support for passing db connection url as seperate `DATABASE_HOST`, `DATABASE_USERNAME`, `DATABASE_PASSWORD`, `DATABASE_NAME`, and `DATABASE_ARGS` env vars. [#545](https://github.com/sourcebot-dev/sourcebot/pull/545)

View file

@ -2,13 +2,10 @@ import { auth } from "@/auth";
import { LoginForm } from "./components/loginForm";
import { redirect } from "next/navigation";
import { Footer } from "@/app/components/footer";
import { createLogger } from "@sourcebot/logger";
import { getAuthProviders } from "@/lib/authProviders";
import { getOrgFromDomain } from "@/data/org";
import { SINGLE_TENANT_ORG_DOMAIN } from "@/lib/constants";
const logger = createLogger('login-page');
interface LoginProps {
searchParams: Promise<{
callbackUrl?: string;
@ -18,10 +15,8 @@ interface LoginProps {
export default async function Login(props: LoginProps) {
const searchParams = await props.searchParams;
logger.info("Login page loaded");
const session = await auth();
if (session) {
logger.info("Session found in login page, redirecting to home");
return redirect("/");
}