Skip to content

Commit 3fbb9b2

Browse files
julienwKoooooo-7
andauthored
Fix the end condition for the embed content handling loop (#1824)
Co-authored-by: Koy Zhuang <[email protected]>
1 parent 84ac82d commit 3fbb9b2

File tree

1 file changed

+2
-2
lines changed

1 file changed

+2
-2
lines changed

src/core/render/embed.js

+2-2
Original file line numberDiff line numberDiff line change
@@ -7,7 +7,7 @@ const cached = {};
77
function walkFetchEmbed({ embedTokens, compile, fetch }, cb) {
88
let token;
99
let step = 0;
10-
let count = 1;
10+
let count = 0;
1111

1212
if (!embedTokens.length) {
1313
return cb({});
@@ -73,7 +73,7 @@ function walkFetchEmbed({ embedTokens, compile, fetch }, cb) {
7373
}
7474

7575
cb({ token, embedToken });
76-
if (++count >= step) {
76+
if (++count >= embedTokens.length) {
7777
cb({});
7878
}
7979
};

0 commit comments

Comments
 (0)