From 5e4decbe967ec28f9263bcb1d9907ee86262b91e Mon Sep 17 00:00:00 2001 From: kamtschatka Date: Sat, 27 Jul 2024 22:32:37 +0200 Subject: feature(cli): Allow updating tags/lists from CLI (#211) * Improve the CLI #209 added the possibility to assign tags to bookmarks while creating added the possibility to assign a newly created to a list right away added the possibility to add and remove tags from bookmarks * minor tweaks --------- Co-authored-by: MohamedBassem --- apps/browser-extension/src/components/TagsSelector.tsx | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) (limited to 'apps/browser-extension/src') diff --git a/apps/browser-extension/src/components/TagsSelector.tsx b/apps/browser-extension/src/components/TagsSelector.tsx index 45cf11d5..5ca3b2d0 100644 --- a/apps/browser-extension/src/components/TagsSelector.tsx +++ b/apps/browser-extension/src/components/TagsSelector.tsx @@ -32,14 +32,14 @@ export function TagsSelector({ bookmarkId }: { bookmarkId: string }) { const { mutate } = useUpdateBookmarkTags({ onMutate: (req) => { req.attach.forEach((t) => currentlyUpdating.add(t.tagId ?? "")); - req.detach.forEach((t) => currentlyUpdating.add(t.tagId)); + req.detach.forEach((t) => currentlyUpdating.add(t.tagId ?? "")); }, onSettled: (_resp, _err, req) => { if (!req) { return; } req.attach.forEach((t) => currentlyUpdating.delete(t.tagId ?? "")); - req.detach.forEach((t) => currentlyUpdating.delete(t.tagId)); + req.detach.forEach((t) => currentlyUpdating.delete(t.tagId ?? "")); }, }); -- cgit v1.2.3-70-g09d2