diff --git a/src/createServerClient.ts b/src/createServerClient.ts index 2605371..eb77411 100644 --- a/src/createServerClient.ts +++ b/src/createServerClient.ts @@ -32,7 +32,7 @@ export function createServerClient< : string & keyof Database, Schema extends GenericSchema = Database[SchemaName] extends GenericSchema ? Database[SchemaName] - : any, + : any >( supabaseUrl: string, supabaseKey: string, @@ -40,7 +40,7 @@ export function createServerClient< cookieOptions?: CookieOptionsWithName; cookies: CookieMethodsServerDeprecated; cookieEncoding?: "raw" | "base64url"; - }, + } ): SupabaseClient; /** @@ -111,7 +111,7 @@ export function createServerClient< : string & keyof Database, Schema extends GenericSchema = Database[SchemaName] extends GenericSchema ? Database[SchemaName] - : any, + : any >( supabaseUrl: string, supabaseKey: string, @@ -119,7 +119,7 @@ export function createServerClient< cookieOptions?: CookieOptionsWithName; cookies: CookieMethodsServer; cookieEncoding?: "raw" | "base64url"; - }, + } ): SupabaseClient; export function createServerClient< @@ -129,7 +129,7 @@ export function createServerClient< : string & keyof Database, Schema extends GenericSchema = Database[SchemaName] extends GenericSchema ? Database[SchemaName] - : any, + : any >( supabaseUrl: string, supabaseKey: string, @@ -137,11 +137,11 @@ export function createServerClient< cookieOptions?: CookieOptionsWithName; cookies: CookieMethodsServer | CookieMethodsServerDeprecated; cookieEncoding?: "raw" | "base64url"; - }, + } ): SupabaseClient { if (!supabaseUrl || !supabaseKey) { throw new Error( - `Your project's URL and Key are required to create a Supabase client!\n\nCheck your Supabase project's API settings to find these values\n\nhttps://supabase.com/dashboard/project/_/settings/api`, + `Your project's URL and Key are required to create a Supabase client!\n\nCheck your Supabase project's API settings to find these values\n\nhttps://supabase.com/dashboard/project/_/settings/api` ); } @@ -151,7 +151,7 @@ export function createServerClient< ...options, cookieEncoding: options?.cookieEncoding ?? "base64url", }, - true, + true ); const client = createClient( @@ -177,7 +177,7 @@ export function createServerClient< persistSession: true, storage, }, - }, + } ); client.auth.onAuthStateChange(async (event) => { @@ -201,7 +201,7 @@ export function createServerClient< { cookieOptions: options?.cookieOptions ?? null, cookieEncoding: options?.cookieEncoding ?? "base64url", - }, + } ); } });