Skip to content

Commit 407bc5d

Browse files
Update crates/cli-support/src/js/closures.rs
Co-Authored-By: alexcrichton <[email protected]>
1 parent 2ff2e25 commit 407bc5d

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

crates/cli-support/src/js/closures.rs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -198,7 +198,7 @@ impl ClosureDescriptors {
198198
.prelude("this.a = 0;")
199199
.rust_argument("a")
200200
.rust_argument("b")
201-
.finally("if (this.cnt-- == 1) d(a, b);")
201+
.finally("if (--this.cnt === 0) d(a, b);")
202202
.finally("else this.a = a;");
203203
} else {
204204
// For shared closures they can be invoked recursively so we

0 commit comments

Comments
 (0)