refactor: simplify gateway status issue filters

This commit is contained in:
Peter Steinberger
2026-04-11 00:30:32 +01:00
parent 242a91bd0d
commit a23108c795

View File

@@ -215,13 +215,15 @@ export function extractConfigSummary(snapshotUnknown: unknown): GatewayConfigSum
exists,
valid,
issues: issuesRaw
.filter((i): i is { path: string; message: string } =>
Boolean(i && typeof i.path === "string" && typeof i.message === "string"),
.filter(
(i): i is { path: string; message: string } =>
i && typeof i.path === "string" && typeof i.message === "string",
)
.map((i) => ({ path: i.path, message: i.message })),
legacyIssues: legacyRaw
.filter((i): i is { path: string; message: string } =>
Boolean(i && typeof i.path === "string" && typeof i.message === "string"),
.filter(
(i): i is { path: string; message: string } =>
i && typeof i.path === "string" && typeof i.message === "string",
)
.map((i) => ({ path: i.path, message: i.message })),
gateway: {