Fix pushed after double down showing wrong visual indicator (#214)

Co-authored-by: Chuck <dude@bussy.com>
Reviewed-on: #214
Co-authored-by: top <top@noreply.fsdfsd.net>
Co-committed-by: top <top@noreply.fsdfsd.net>
pull/216/head
top 2023-10-13 12:19:10 +00:00 committed by Aevann
parent f84bae558c
commit 89615a7a53
1 changed files with 1 additions and 1 deletions

View File

@ -186,7 +186,7 @@ function updateCardsetBackgrounds(state, complete = false) {
if(complete){
const wager = state.has_player_split ? state?.wager?.amount * 2 : state?.wager?.amount;
let dealerShows = state.payout < wager ? 'WON': 'LOST';
if(state.payout === wager) dealerShows = 'PUSHED'
if(state.payout === wager || (state.player_doubled_down && state.status === 'PUSHED')) dealerShows = 'PUSHED'
cardsets[0]?.classList.add(`blackjack-cardset__${dealerShows}`)
}
else {