revert(tools): undo accidental merge of PR #18584

This commit is contained in:
Sebastian
2026-02-16 21:13:03 -05:00
parent 0158e41298
commit f924ab40d8
7 changed files with 8 additions and 107 deletions

View File

@@ -8,20 +8,6 @@ export const DEFAULT_TIMEOUT_SECONDS = 30;
export const DEFAULT_CACHE_TTL_MINUTES = 15;
const DEFAULT_CACHE_MAX_ENTRIES = 100;
export function resolveWebUrlAllowlist(web: unknown): string[] | undefined {
if (!web || typeof web !== "object") {
return undefined;
}
if (!("urlAllowlist" in web)) {
return undefined;
}
const allowlist = (web as { urlAllowlist?: unknown }).urlAllowlist;
if (!Array.isArray(allowlist)) {
return undefined;
}
return allowlist.length > 0 ? allowlist : undefined;
}
export function resolveTimeoutSeconds(value: unknown, fallback: number): number {
const parsed = typeof value === "number" && Number.isFinite(value) ? value : fallback;
return Math.max(1, Math.floor(parsed));