feat(notifications): emit at maintenance/turn/sync/reauth events
This commit is contained in:
@@ -378,6 +378,16 @@ const refreshOwnedSpoon = async (
|
||||
error: message,
|
||||
}),
|
||||
]);
|
||||
if (!rateLimited) {
|
||||
await ctx.runMutation(internal.notifications.emit, {
|
||||
userId: ownerId,
|
||||
kind: 'sync_failed',
|
||||
title: `Sync failed for ${spoon.name}`,
|
||||
body: message,
|
||||
link: `/spoons/${spoonId}`,
|
||||
spoonId,
|
||||
});
|
||||
}
|
||||
throw new ConvexError(message);
|
||||
}
|
||||
};
|
||||
|
||||
Reference in New Issue
Block a user