diff --git a/frontend/files/index.html b/frontend/files/index.html index 05718ac..a0ac314 100644 --- a/frontend/files/index.html +++ b/frontend/files/index.html @@ -158,14 +158,7 @@ ISBN = EAN.slice(3, 12); var checkdigit = (11 - - (_.reduce( - ISBN.split(""), - function (sum, num, key) { - return sum + num * (10 - key); - }, - 0 - ) % - 11)) % + (_.reduce(ISBN.split(""), (s, n, k) => s + n * (10 - k), 0) % 11)) % 11; return ISBN + (checkdigit == 10 ? "X" : checkdigit); }