Skip to content

Commit c339a34

Browse files
committed
fix:can't choose same file
1 parent b8b6633 commit c339a34

File tree

1 file changed

+2
-2
lines changed

1 file changed

+2
-2
lines changed

notebook/static/tree/js/notebooklist.js

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -338,11 +338,11 @@ define([
338338
reader.onerror = reader_onerror;
339339
}
340340
});
341-
// Replace the file input form wth a clone of itself. This is required to
341+
// Clear fileinput value. This is required to
342342
// reset the form. Otherwise, if you upload a file, delete it and try to
343343
// upload it again, the changed event won't fire.
344344
var form = $('input.fileinput');
345-
form.replaceWith(form.clone(true));
345+
form.val('');
346346
return false;
347347
};
348348

0 commit comments

Comments
 (0)