Fix: search to find index.html.

This commit is contained in:
Julian Kropff
2026-05-17 16:35:09 +02:00
parent 2ff195c817
commit 92d7294dfd
@@ -1944,13 +1944,23 @@ public class TaskbarController {
try { try {
Path start = Paths.get(System.getProperty("user.dir")); Path start = Paths.get(System.getProperty("user.dir"));
Path file = findFileUpAndDown(start, "index.html", "Gruppe-13"); Path file = start;
if (file == null) { while (file != null && !file.getFileName().toString().equals("Gruppe-13")) {
throw new IllegalStateException("index.html not found"); file = file.getParent();
} }
CasinoBrowserController.open(file.toUri().toString()); if (file == null) {
throw new IllegalStateException("Gruppe-13 not found");
}
Path target = file.resolve("outreach").resolve("index.html");
if (!Files.isRegularFile(target)) {
throw new IllegalStateException("outreach/index.html not found");
}
CasinoBrowserController.open(target.toUri().toString());
} catch (Exception e) { } catch (Exception e) {
e.printStackTrace(); e.printStackTrace();