mirror of
https://github.com/unraid/api.git
synced 2026-05-03 21:50:20 -05:00
refactor(web): move archiveAll cache invalidation into apollo client config
This commit is contained in:
@@ -42,15 +42,7 @@ const notifications = computed(() => {
|
||||
return useFragment(NOTIFICATION_FRAGMENT, result.value?.notifications.list);
|
||||
});
|
||||
|
||||
const { mutate: archiveAll, loading: archivingAll } = useMutation(
|
||||
archiveAllNotifications,
|
||||
{
|
||||
update: (cache) => {
|
||||
cache.evict({ fieldName: "notifications" });
|
||||
cache.gc();
|
||||
},
|
||||
}
|
||||
);
|
||||
const { mutate: archiveAll, loading: archivingAll } = useMutation(archiveAllNotifications);
|
||||
|
||||
watch(error, (newVal) => {
|
||||
console.log("[sidebar error]", newVal);
|
||||
|
||||
Reference in New Issue
Block a user