Skip to content

Commit cf6b633

Browse files
committed
✨ disconnect eventsource for revealed story
1 parent 4da7578 commit cf6b633

File tree

1 file changed

+4
-0
lines changed

1 file changed

+4
-0
lines changed

src/front-end/app/store/story.ts

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -47,6 +47,10 @@ const story: Module<StoryState | Promise<StoryState>, StoreState> = {
4747

4848
console.log("Story", story);
4949
ctx.commit("story", story);
50+
51+
if (story?.revealed) {
52+
ctx.rootState.story.events?.close();
53+
}
5054
},
5155
async "story.reveal"(ctx) {
5256
const state = ctx.state as StoryState;

0 commit comments

Comments
 (0)