From 1cec4e68b16b50b57efaca2a05723daa694ebaa1 Mon Sep 17 00:00:00 2001 From: Athou Date: Wed, 16 Apr 2025 01:16:32 +0200 Subject: [PATCH] remove unused variables --- commafeed-client/biome.json | 3 ++- commafeed-client/src/app/entries/thunks.ts | 2 +- commafeed-client/src/components/content/FeedEntries.tsx | 2 -- commafeed-client/src/components/header/ProfileMenu.tsx | 2 +- 4 files changed, 4 insertions(+), 5 deletions(-) diff --git a/commafeed-client/biome.json b/commafeed-client/biome.json index c0f73273..c3ce2b00 100644 --- a/commafeed-client/biome.json +++ b/commafeed-client/biome.json @@ -16,7 +16,8 @@ "linter": { "rules": { "correctness": { - "noUnusedImports": "error" + "noUnusedImports": "error", + "noUnusedVariables": "error" } } }, diff --git a/commafeed-client/src/app/entries/thunks.ts b/commafeed-client/src/app/entries/thunks.ts index 958139f8..88c5abd1 100644 --- a/commafeed-client/src/app/entries/thunks.ts +++ b/commafeed-client/src/app/entries/thunks.ts @@ -50,7 +50,7 @@ const buildGetEntriesPaginatedRequest = (state: RootState, source: EntrySource, keywords: state.entries.search, }) -export const reloadEntries = createAppAsyncThunk("entries/reload", (arg, thunkApi) => { +export const reloadEntries = createAppAsyncThunk("entries/reload", (_, thunkApi) => { const state = thunkApi.getState() thunkApi.dispatch(loadEntries({ source: state.entries.source, clearSearch: false })) }) diff --git a/commafeed-client/src/components/content/FeedEntries.tsx b/commafeed-client/src/components/content/FeedEntries.tsx index 174ddc1e..56860d2d 100644 --- a/commafeed-client/src/components/content/FeedEntries.tsx +++ b/commafeed-client/src/components/content/FeedEntries.tsx @@ -28,9 +28,7 @@ import { throttle } from "throttle-debounce" import { FeedEntry } from "./FeedEntry" export function FeedEntries() { - const source = useAppSelector(state => state.entries.source) const entries = useAppSelector(state => state.entries.entries) - const entriesTimestamp = useAppSelector(state => state.entries.timestamp) const selectedEntryId = useAppSelector(state => state.entries.selectedEntryId) const hasMore = useAppSelector(state => state.entries.hasMore) const loading = useAppSelector(state => state.entries.loading) diff --git a/commafeed-client/src/components/header/ProfileMenu.tsx b/commafeed-client/src/components/header/ProfileMenu.tsx index 563319c6..d9ea740f 100644 --- a/commafeed-client/src/components/header/ProfileMenu.tsx +++ b/commafeed-client/src/components/header/ProfileMenu.tsx @@ -143,7 +143,7 @@ export function ProfileMenu(props: ProfileMenuProps) { color: "green", autoClose: 1000, }) - } catch (error) { + } catch (_) { showNotification({ message: Force fetching feeds is not yet available., color: "red",