From 8d265c400c3ab2b4f440062223223b83f6306acf Mon Sep 17 00:00:00 2001 From: Jonathan Bernard Date: Fri, 11 Dec 2020 15:33:18 -0600 Subject: [PATCH] Prevent the importFromURL button from submitting the form. --- flashcards.js | 2 ++ 1 file changed, 2 insertions(+) diff --git a/flashcards.js b/flashcards.js index 7c94530..b8d8c2c 100644 --- a/flashcards.js +++ b/flashcards.js @@ -272,6 +272,8 @@ }; FC.importCardSetFromURL = function(ev) { + ev.preventDefault(); + fetch(FC.$('input[name=importURL]').value) .then(resp => resp.json()) .then(set => {