mirror of
https://github.com/openclaw/openclaw.git
synced 2026-04-10 16:51:13 +00:00
8 lines
218 B
TypeScript
8 lines
218 B
TypeScript
export function normalizeSlackWebhookPath(path?: string | null): string {
|
|
const trimmed = path?.trim();
|
|
if (!trimmed) {
|
|
return "/slack/events";
|
|
}
|
|
return trimmed.startsWith("/") ? trimmed : `/${trimmed}`;
|
|
}
|