Skip to content

Commit f0d5861

Browse files
mehulmptcaisq
authored andcommitted
Closure not needed for let variable (#336)
`idx` is not required. `i` is already in a closure as `let` is used.
1 parent f099159 commit f0d5861

File tree

1 file changed

+0
-2
lines changed

1 file changed

+0
-2
lines changed

Diff for: mobilenet/index.js

-2
Original file line numberDiff line numberDiff line change
@@ -172,8 +172,6 @@ filesElement.addEventListener('change', evt => {
172172
continue;
173173
}
174174
let reader = new FileReader();
175-
const idx = i;
176-
// Closure to capture the file information.
177175
reader.onload = e => {
178176
// Fill the image & call predict.
179177
let img = document.createElement('img');

0 commit comments

Comments
 (0)