From cdd87d89f831ade526b2b4c13a5576fd6a0dd077 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?marcin=20miko=C5=82ajczak?= Date: Sun, 10 Nov 2024 19:53:31 +0100 Subject: [PATCH] pl-fe: fix wrong type MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Signed-off-by: marcin mikołajczak --- packages/pl-fe/src/reducers/contexts.ts | 11 +++-------- 1 file changed, 3 insertions(+), 8 deletions(-) diff --git a/packages/pl-fe/src/reducers/contexts.ts b/packages/pl-fe/src/reducers/contexts.ts index c23ffe31a..070fc7030 100644 --- a/packages/pl-fe/src/reducers/contexts.ts +++ b/packages/pl-fe/src/reducers/contexts.ts @@ -1,6 +1,3 @@ -import { - Map as ImmutableMap, -} from 'immutable'; import { create } from 'mutative'; import { STATUS_IMPORT, STATUSES_IMPORT, type ImporterAction } from 'pl-fe/actions/importer'; @@ -143,13 +140,11 @@ const filterContexts = ( state: State, relationship: { id: string }, /** The entire statuses map from the store. */ - statuses: ImmutableMap, + statuses: Record, ) => { - const ownedStatusIds = statuses + const ownedStatusIds = Object.values(statuses) .filter(status => status.account.id === relationship.id) - .map(status => status.id) - .toList() - .toArray(); + .map(status => status.id); deleteStatuses(state, ownedStatusIds); };