diff options
| -rw-r--r-- | webAO/client.js | 19 |
1 files changed, 1 insertions, 18 deletions
diff --git a/webAO/client.js b/webAO/client.js index 7b0c9cd..d6ab5fb 100644 --- a/webAO/client.js +++ b/webAO/client.js @@ -781,24 +781,7 @@ class Client extends EventEmitter { if (chargs[0]) { let cini = {}; const cswap = {}; - - const getCharIcon = async () => { - const extensions = [ - '.png', - '.webp', - ]; - const charIconBaseUrl = `${AO_HOST}characters/${encodeURI(chargs[0].toLowerCase())}/char_icon`; - for (let i = 0; i < extensions.length; i++) { - const fileUrl = charIconBaseUrl + extensions[i]; - const exists = await fileExists(fileUrl); - if (exists) { - return fileUrl; - } - } - }; - - const charIconUrlResponse = await getCharIcon(); - const icon = charIconUrlResponse || transparentPNG; + const icon = `${AO_HOST}characters/${encodeURI(chargs[0].toLowerCase())}/char_icon.png`; const img = document.getElementById(`demo_${charid}`); img.alt = chargs[0]; |
