mirror of
https://github.com/pacnpal/thrilltrack-explorer.git
synced 2025-12-24 18:11:12 -05:00
feat: Implement auth logging and session verification optimizations
This commit is contained in:
23
src/lib/authLogger.ts
Normal file
23
src/lib/authLogger.ts
Normal file
@@ -0,0 +1,23 @@
|
||||
/**
|
||||
* Conditional authentication logging utility
|
||||
* Logs are only shown in development mode
|
||||
*/
|
||||
|
||||
const isDevelopment = import.meta.env.DEV;
|
||||
|
||||
export const authLog = (...args: any[]) => {
|
||||
if (isDevelopment) {
|
||||
console.log(...args);
|
||||
}
|
||||
};
|
||||
|
||||
export const authWarn = (...args: any[]) => {
|
||||
if (isDevelopment) {
|
||||
console.warn(...args);
|
||||
}
|
||||
};
|
||||
|
||||
export const authError = (...args: any[]) => {
|
||||
// Always log errors
|
||||
console.error(...args);
|
||||
};
|
||||
Reference in New Issue
Block a user