fix: resolve 3 lint issues
- login-form.tsx: suppress unused-vars warning for emailChecked state - bookmark-button.tsx: use function initializer for isLoading to avoid sync setState in effect - saved-games.ts: remove unused 'set' parameter from check endpoint
This commit is contained in:
@@ -13,14 +13,11 @@ interface BookmarkButtonProps {
|
||||
export function BookmarkButton({ gameId, className = "" }: BookmarkButtonProps) {
|
||||
const { data: session } = useSession()
|
||||
const [isSaved, setIsSaved] = useState(false)
|
||||
const [isLoading, setIsLoading] = useState(true)
|
||||
const [isLoading, setIsLoading] = useState(() => !session)
|
||||
const [isToggling, setIsToggling] = useState(false)
|
||||
|
||||
useEffect(() => {
|
||||
if (!session) {
|
||||
setIsLoading(false)
|
||||
return
|
||||
}
|
||||
if (!session) return
|
||||
|
||||
async function checkSaved() {
|
||||
try {
|
||||
|
||||
Reference in New Issue
Block a user