mirror of
https://github.com/pacnpal/thrilltrack-explorer.git
synced 2025-12-20 17:11:13 -05:00
Fix and test error logging
This commit is contained in:
@@ -5,14 +5,18 @@
|
||||
import { Button } from '@/components/ui/button';
|
||||
import { handleError } from '@/lib/errorHandler';
|
||||
import { supabase } from '@/lib/supabaseClient';
|
||||
import { useAuth } from '@/hooks/useAuth';
|
||||
|
||||
export function TestErrorLogging() {
|
||||
const { user } = useAuth();
|
||||
|
||||
const testError = () => {
|
||||
try {
|
||||
throw new Error('Test error for logging system verification');
|
||||
} catch (error) {
|
||||
handleError(error, {
|
||||
action: 'Test Error Logging',
|
||||
userId: user?.id,
|
||||
metadata: { test: true }
|
||||
});
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user