Do not play sounds on initial load.
This commit is contained in:
parent
404c82f427
commit
a1ed58f6e6
1 changed files with 4 additions and 1 deletions
|
@ -81,7 +81,10 @@ class App.CustomerChat extends App.Controller
|
||||||
|
|
||||||
# play on changes
|
# play on changes
|
||||||
if @lastWaitingChatCount isnt counter
|
if @lastWaitingChatCount isnt counter
|
||||||
@sounds.chat_new.play()
|
|
||||||
|
# do not play sound on initial load
|
||||||
|
if counter > 0 && @lastWaitingChatCount isnt undefined
|
||||||
|
@sounds.chat_new.play()
|
||||||
@lastWaitingChatCount = counter
|
@lastWaitingChatCount = counter
|
||||||
|
|
||||||
# collect chat window messages
|
# collect chat window messages
|
||||||
|
|
Loading…
Reference in a new issue