fix bug where no scrubs would show if sub list was empty
This commit is contained in:
@@ -73,8 +73,9 @@ const ChatttersView: Component<{
|
|||||||
const [search, setSearch] = createSignal<string>("");
|
const [search, setSearch] = createSignal<string>("");
|
||||||
const subs = sortBy(props.subscriptions, ["user_name"]);
|
const subs = sortBy(props.subscriptions, ["user_name"]);
|
||||||
const scrubs = sortBy(
|
const scrubs = sortBy(
|
||||||
props.chatters.filter((chat) =>
|
props.chatters.filter(
|
||||||
props.subscriptions.find((sub) => sub.user_id !== chat.user_id),
|
(chat) =>
|
||||||
|
!props.subscriptions.find((sub) => sub.user_id === chat.user_id),
|
||||||
),
|
),
|
||||||
["user_name"],
|
["user_name"],
|
||||||
);
|
);
|
||||||
|
|||||||
Reference in New Issue
Block a user