Skip to content

Commit

Permalink
fix
Browse files Browse the repository at this point in the history
  • Loading branch information
NormanTUD committed Oct 27, 2023
1 parent 2d9dccc commit bd1f3be
Showing 1 changed file with 9 additions and 0 deletions.
9 changes: 9 additions & 0 deletions model.js
Original file line number Diff line number Diff line change
Expand Up @@ -1450,6 +1450,15 @@ async function set_weights_from_string (string, no_warning, no_error, m) {
}

err("" + e);

if(("" + e).includes("JSON.parse:")) {
Swal.fire({
icon: 'error',
title: 'Oops...',
text: 'The weights.json file you uploaded did not contain valid JSON. Do not use the .bin-file. Use the .json-file.'
})
err("" + e);
}
}
}

Expand Down

0 comments on commit bd1f3be

Please sign in to comment.