From 63689b7a264eb12400033945b0b3d02ae093009f Mon Sep 17 00:00:00 2001 From: Janis Date: Thu, 23 Oct 2025 11:08:08 +0200 Subject: [PATCH] refactor(ui): Fixed UI Code Smell (#19) Reviewed-on: https://git.janis-eccarius.de/KnockOutWhist/KnockOutWhist-Web/pulls/19 Reviewed-by: lq64 --- knockoutwhistweb/app/views/ingame.scala.html | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/knockoutwhistweb/app/views/ingame.scala.html b/knockoutwhistweb/app/views/ingame.scala.html index 3f63dd6..379f219 100644 --- a/knockoutwhistweb/app/views/ingame.scala.html +++ b/knockoutwhistweb/app/views/ingame.scala.html @@ -14,7 +14,7 @@

First Card

- @if(logic.getCurrentTrick.get.firstCard != None) { + @if(logic.getCurrentTrick.get.firstCard.isDefined) { @util.WebUIUtils.cardtoImage(logic.getCurrentTrick.get.firstCard.get) } else { @views.html.output.card.apply("images/cards/1B.png")("Blank Card") @@ -23,7 +23,7 @@

@logic.getCurrentPlayer.get has to play a card!

- @if(!logic.getCurrentTrick.get.cards.isEmpty) { + @if(logic.getCurrentTrick.get.cards.nonEmpty) {

Cards played

} else {

Cards played