From 7dea7919c5ad76743685f11a00fbdfd34ed0735e Mon Sep 17 00:00:00 2001 From: Andrin Fassbind Date: Fri, 13 May 2022 16:12:06 +0200 Subject: [PATCH] AlertDelete shortened code --- .../turnierverwaltung/main/tournamentList/AlertDelete.java | 4 +--- 1 file changed, 1 insertion(+), 3 deletions(-) diff --git a/app/src/main/java/ch/zhaw/projekt2/turnierverwaltung/main/tournamentList/AlertDelete.java b/app/src/main/java/ch/zhaw/projekt2/turnierverwaltung/main/tournamentList/AlertDelete.java index 6c400dd..8aada10 100644 --- a/app/src/main/java/ch/zhaw/projekt2/turnierverwaltung/main/tournamentList/AlertDelete.java +++ b/app/src/main/java/ch/zhaw/projekt2/turnierverwaltung/main/tournamentList/AlertDelete.java @@ -21,9 +21,7 @@ public class AlertDelete extends Alert { public boolean showAndGetResult() { result = false; showAndWait().ifPresent(type -> { - if (type == yesButton) { - result = true; - } + result = type == yesButton; }); return result; }