refactor: remove stale extension helpers · openclaw/openclaw@48b39bf
steipete
·
2026-05-01
·
via Recent Commits to openclaw:main
File tree
google-meet/src/transports
mattermost/src/mattermost
| Original file line number | Diff line number | Diff line change |
|---|
@@ -699,10 +699,6 @@ export async function recoverCurrentMeetTabOnNode(params: {
|
699 | 699 | }; |
700 | 700 | } |
701 | 701 | |
702 | | -export type GoogleMeetCurrentTabRecoveryResult = Awaited< |
703 | | -ReturnType<typeof recoverCurrentMeetTab | typeof recoverCurrentMeetTabOnNode> |
704 | | ->; |
705 | | - |
706 | 702 | export async function launchChromeMeetOnNode(params: { |
707 | 703 | runtime: PluginRuntime; |
708 | 704 | config: GoogleMeetConfig; |
|
| Original file line number | Diff line number | Diff line change |
|---|
@@ -537,22 +537,6 @@ export function isSlashCommandsEnabled(config: MattermostSlashCommandConfig): bo
|
537 | 537 | return false; |
538 | 538 | } |
539 | 539 | |
540 | | -export function collectMattermostSlashCallbackPaths(raw?: Partial<MattermostSlashCommandConfig>) { |
541 | | -const config = resolveSlashCommandConfig(raw); |
542 | | -const paths = new Set<string>([config.callbackPath]); |
543 | | -if (typeof config.callbackUrl === "string" && config.callbackUrl.trim()) { |
544 | | -try { |
545 | | -const pathname = new URL(config.callbackUrl).pathname; |
546 | | -if (pathname) { |
547 | | -paths.add(pathname); |
548 | | -} |
549 | | -} catch { |
550 | | -// Ignore invalid callback URLs and keep the normalized callback path only. |
551 | | -} |
552 | | -} |
553 | | -return [...paths]; |
554 | | -} |
555 | | - |
556 | 540 | /** |
557 | 541 | * Build the callback URL that Mattermost will POST to when a command is invoked. |
558 | 542 | */ |
|
| Original file line number | Diff line number | Diff line change |
|---|
|
1 | 1 | import type { IncomingMessage, ServerResponse } from "node:http"; |
2 | 2 | import type { Mock } from "vitest"; |
3 | 3 | import { vi } from "vitest"; |
4 | | -import type { ResolvedSynologyChatAccount } from "./types.js"; |
5 | 4 | |
6 | 5 | export type RegisteredRoute = { |
7 | 6 | path: string; |
@@ -175,25 +174,3 @@ vi.mock("./runtime.js", () => ({
|
175 | 174 | })), |
176 | 175 | setSynologyRuntime: vi.fn(), |
177 | 176 | })); |
178 | | - |
179 | | -export function makeSecurityAccount( |
180 | | -overrides: Partial<ResolvedSynologyChatAccount> = {}, |
181 | | -): ResolvedSynologyChatAccount { |
182 | | -return { |
183 | | -accountId: "default", |
184 | | -enabled: true, |
185 | | -token: "t", |
186 | | -incomingUrl: "https://nas/incoming", |
187 | | -nasHost: "h", |
188 | | -webhookPath: "/w", |
189 | | -webhookPathSource: "default", |
190 | | -dangerouslyAllowNameMatching: false, |
191 | | -dangerouslyAllowInheritedWebhookPath: false, |
192 | | -dmPolicy: "allowlist" as const, |
193 | | -allowedUserIds: [], |
194 | | -rateLimitPerMinute: 30, |
195 | | -botName: "Bot", |
196 | | -allowInsecureSsl: false, |
197 | | - ...overrides, |
198 | | -}; |
199 | | -} |
| Original file line number | Diff line number | Diff line change |
|---|
@@ -5,7 +5,6 @@ import {
|
5 | 5 | XAI_RESPONSES_ENDPOINT, |
6 | 6 | } from "./responses-tool-shared.js"; |
7 | 7 | import { |
8 | | -coerceXaiToolConfig, |
9 | 8 | resolveNormalizedXaiToolModel, |
10 | 9 | resolvePositiveIntegerToolConfig, |
11 | 10 | } from "./tool-config-shared.js"; |
@@ -14,12 +13,6 @@ import { type XaiWebSearchResponse } from "./web-search-shared.js";
|
14 | 13 | export const XAI_CODE_EXECUTION_ENDPOINT = XAI_RESPONSES_ENDPOINT; |
15 | 14 | export const XAI_DEFAULT_CODE_EXECUTION_MODEL = "grok-4-1-fast"; |
16 | 15 | |
17 | | -export type XaiCodeExecutionConfig = { |
18 | | -apiKey?: unknown; |
19 | | -model?: unknown; |
20 | | -maxTurns?: unknown; |
21 | | -}; |
22 | | - |
23 | 16 | export type XaiCodeExecutionResponse = XaiWebSearchResponse & { |
24 | 17 | output?: Array<{ |
25 | 18 | type?: string; |
@@ -33,12 +26,6 @@ export type XaiCodeExecutionResult = {
|
33 | 26 | outputTypes: string[]; |
34 | 27 | }; |
35 | 28 | |
36 | | -export function resolveXaiCodeExecutionConfig( |
37 | | -config?: Record<string, unknown>, |
38 | | -): XaiCodeExecutionConfig { |
39 | | -return coerceXaiToolConfig(config) as XaiCodeExecutionConfig; |
40 | | -} |
41 | | - |
42 | 29 | export function resolveXaiCodeExecutionModel(config?: Record<string, unknown>): string { |
43 | 30 | return resolveNormalizedXaiToolModel({ |
44 | 31 | config, |
|
此内容由惯性聚合(RSS阅读器)自动聚合整理,仅供阅读参考。 原文来自 — 版权归原作者所有。