$liste]); case "read": jsonAntwort(logLesen( $_GET["datei"] ?? "", $_GET["anzahl"] ?? 300, trim((string) ($_GET["suche"] ?? "")), strtoupper(trim((string) ($_GET["level"] ?? ""))) )); default: jsonAntwort(["error" => "Unbekannte Aktion."], 400); } } catch (InvalidArgumentException $e) { jsonAntwort(["error" => $e->getMessage()], 400); } catch (Throwable $e) { jsonAntwort(["error" => $e->getMessage()], 500); }