Changeset 8496f3c for src/lib/auth.ts
- Timestamp:
- 09/15/26 21:16:02 (8 days ago)
- Branches:
- master
- Children:
- b8093a0
- Parents:
- 4fe4582
- File:
-
- 1 edited
-
src/lib/auth.ts (modified) (3 diffs)
Legend:
- Unmodified
- Added
- Removed
-
src/lib/auth.ts
r4fe4582 r8496f3c 1 import { API_BASE_URL } from './api'; 1 2 export type AuthTokens = { 2 3 accessToken: string; … … 4 5 }; 5 6 6 export type UserRole = 'Professor' | 'Student' | string;7 export type UserRole = 'Professor' | 'Student' | 'Admin' | string; 7 8 8 9 export type AuthSession = AuthTokens & { … … 91 92 92 93 export async function login(params: { email: string; password: string }): Promise<AuthSession> { 93 const baseUrl = process.env.NEXT_PUBLIC_API_BASE_URL ?? 'https://iknow-api.onrender.com';94 const baseUrl = API_BASE_URL; 94 95 95 96 const response = await fetch(`${baseUrl}/api/auth/login`, {
Note:
See TracChangeset
for help on using the changeset viewer.
