From 8f160796233825da2fc3576fb36916099ce9b2fc Mon Sep 17 00:00:00 2001 From: Peter Steinberger Date: Fri, 1 May 2026 15:50:14 +0100 Subject: [PATCH] refactor: trim mattermost helper exports --- extensions/mattermost/src/channel-config-shared.ts | 9 +++------ extensions/mattermost/src/doctor.ts | 2 +- 2 files changed, 4 insertions(+), 7 deletions(-) diff --git a/extensions/mattermost/src/channel-config-shared.ts b/extensions/mattermost/src/channel-config-shared.ts index 4b97595f4a7..bcd28cb066d 100644 --- a/extensions/mattermost/src/channel-config-shared.ts +++ b/extensions/mattermost/src/channel-config-shared.ts @@ -5,10 +5,7 @@ import { createScopedChannelConfigAdapter, } from "openclaw/plugin-sdk/channel-config-helpers"; import { normalizeLowercaseStringOrEmpty } from "openclaw/plugin-sdk/text-runtime"; -import { - collectMattermostSlashCallbackPaths, - resolveMattermostGatewayAuthBypassPaths, -} from "./gateway-auth-bypass.js"; +import { resolveMattermostGatewayAuthBypassPaths } from "./gateway-auth-bypass.js"; import { listMattermostAccountIds, resolveDefaultMattermostAccountId, @@ -38,7 +35,7 @@ export function normalizeMattermostAllowEntry(entry: string): string { ); } -export function formatMattermostAllowEntry(entry: string): string { +function formatMattermostAllowEntry(entry: string): string { const trimmed = entry.trim(); if (!trimmed) { return ""; @@ -50,7 +47,7 @@ export function formatMattermostAllowEntry(entry: string): string { return normalizeLowercaseStringOrEmpty(trimmed.replace(/^(mattermost|user):/i, "")); } -export { collectMattermostSlashCallbackPaths, resolveMattermostGatewayAuthBypassPaths }; +export { resolveMattermostGatewayAuthBypassPaths }; export const mattermostConfigAdapter = createScopedChannelConfigAdapter({ sectionKey: "mattermost", diff --git a/extensions/mattermost/src/doctor.ts b/extensions/mattermost/src/doctor.ts index d7f35076898..1e9460c161a 100644 --- a/extensions/mattermost/src/doctor.ts +++ b/extensions/mattermost/src/doctor.ts @@ -25,7 +25,7 @@ function isMattermostMutableAllowEntry(raw: string): boolean { return true; } -export const collectMattermostMutableAllowlistWarnings = +const collectMattermostMutableAllowlistWarnings = createDangerousNameMatchingMutableAllowlistWarningCollector({ channel: "mattermost", detector: isMattermostMutableAllowEntry,