refactor: dedupe helper trim readers

This commit is contained in:
Peter Steinberger
2026-04-07 08:21:53 +01:00
parent a5ff85f01c
commit b3e6822ef8
13 changed files with 46 additions and 27 deletions

View File

@@ -12,6 +12,7 @@ import {
logWebhookError,
logWebhookProcessed,
logWebhookReceived,
normalizeOptionalString,
startDiagnosticHeartbeat,
stopDiagnosticHeartbeat,
} from "openclaw/plugin-sdk/text-runtime";
@@ -106,7 +107,7 @@ function hasValidTelegramWebhookSecret(
}
function parseIpLiteral(value: string | undefined): string | undefined {
const trimmed = value?.trim();
const trimmed = normalizeOptionalString(value);
if (!trimmed) {
return undefined;
}