From abf87b75f8a57e6de0ef7349f6577a0e1c39ce1b Mon Sep 17 00:00:00 2001 From: stonedDiscord Date: Wed, 20 Sep 2023 12:14:22 +0200 Subject: no more eslint errors --- webAO/utils/fileExists.js | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) (limited to 'webAO/utils/fileExists.js') diff --git a/webAO/utils/fileExists.js b/webAO/utils/fileExists.js index 7978cbc..a4b3b80 100644 --- a/webAO/utils/fileExists.js +++ b/webAO/utils/fileExists.js @@ -1,7 +1,7 @@ -const fileExists = async (url) => new Promise((resolve, reject) => { +const fileExists = async (url) => new Promise((resolve) => { const xhr = new XMLHttpRequest(); xhr.open('HEAD', url); - xhr.onload = function (e) { + xhr.onload = function checkLoad() { if (xhr.readyState === 4) { if (xhr.status === 200) { resolve(true); @@ -10,7 +10,7 @@ const fileExists = async (url) => new Promise((resolve, reject) => { } } }; - xhr.onerror = function (e) { + xhr.onerror = function checkError() { resolve(false); }; xhr.send(null); -- cgit