fix: resolve linting errors
- Remove unused parameters in logout route - Remove unused AnimatePresence import - Remove unused handleLogout function
This commit is contained in:
@@ -1,7 +1,7 @@
|
||||
"use client";
|
||||
|
||||
import { useState, useEffect, useCallback } from 'react';
|
||||
import { motion, AnimatePresence } from 'framer-motion';
|
||||
import { motion } from 'framer-motion';
|
||||
import { Lock, Loader2 } from 'lucide-react';
|
||||
import ModernAdminDashboard from '@/components/ModernAdminDashboard';
|
||||
|
||||
@@ -157,18 +157,6 @@ const AdminPage = () => {
|
||||
}
|
||||
}, [authState.csrfToken, authState.isLocked, checkSession]);
|
||||
|
||||
// Handle logout
|
||||
const handleLogout = useCallback(() => {
|
||||
sessionStorage.removeItem('admin_authenticated');
|
||||
sessionStorage.removeItem('admin_session_token');
|
||||
setAuthState(prev => ({
|
||||
...prev,
|
||||
isAuthenticated: false,
|
||||
showLogin: true,
|
||||
password: '',
|
||||
error: ''
|
||||
}));
|
||||
}, []);
|
||||
|
||||
// Handle login form submission
|
||||
const handleLogin = async (e: React.FormEvent) => {
|
||||
|
||||
Reference in New Issue
Block a user