From 53109798db90f1066b32d0b8d411588ef5965520 Mon Sep 17 00:00:00 2001 From: sD Date: Thu, 27 Feb 2020 21:07:20 +0100 Subject: don't try to load empty sounds --- webAO/client.js | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/webAO/client.js b/webAO/client.js index f49e336..999f93a 100644 --- a/webAO/client.js +++ b/webAO/client.js @@ -1657,7 +1657,7 @@ class Viewport { if (!this.sfxplayed && this.chatmsg.snddelay + this.shoutTimer >= this.textTimer) { this.sfxaudio.pause(); this.sfxplayed = 1; - if (this.chatmsg.sound !== "0" && this.chatmsg.sound !== "1") { + if (this.chatmsg.sound !== "0" && this.chatmsg.sound !== "1" && this.chatmsg.sound !== "" && this.chatmsg.sound !== undefined) { this.sfxaudio.src = AO_HOST + "sounds/general/" + encodeURI(this.chatmsg.sound.toLowerCase()) + ".wav"; this.sfxaudio.play(); } -- cgit