Skip to content

Commit cd5fa61

Browse files
committed
userClip, more explicit workflow logic
1 parent a043980 commit cd5fa61

File tree

1 file changed

+8
-8
lines changed

1 file changed

+8
-8
lines changed

src/component/workflow.ts

Lines changed: 8 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -199,15 +199,15 @@ export class Workflow {
199199
}
200200
break;
201201
case Process.preFetch:
202-
if (payload === Process.userClip) {
202+
const userClip = payload === Process.userClip;
203+
if (status === Status.done && !userClip) {
204+
run(End)(process);
205+
}
206+
if (status === Status.next && !userClip) {
207+
run(Fetch)();
208+
}
209+
if (userClip) {
203210
run(PreClip)();
204-
} else {
205-
if (status === Status.done) {
206-
run(End)(process);
207-
}
208-
if (status === Status.next) {
209-
run(Fetch)();
210-
}
211211
}
212212
break;
213213
case Process.fetch:

0 commit comments

Comments
 (0)