refactor: trim helper shape exports · openclaw/openclaw@ca2cd6a
steipete
·
2026-05-02
·
via Recent Commits to openclaw:main
| Original file line number | Diff line number | Diff line change |
|---|
@@ -13,12 +13,12 @@ import { initializeMemoryWikiVault } from "./vault.js";
|
13 | 13 | |
14 | 14 | const MEMORY_WIKI_TEST_HOME = "/Users/tester"; |
15 | 15 | |
16 | | -export type MemoryWikiTestVault = { |
| 16 | +type MemoryWikiTestVault = { |
17 | 17 | rootDir: string; |
18 | 18 | config: ResolvedMemoryWikiConfig; |
19 | 19 | }; |
20 | 20 | |
21 | | -export type MemoryWikiPluginApiHarness = { |
| 21 | +type MemoryWikiPluginApiHarness = { |
22 | 22 | api: OpenClawPluginApi; |
23 | 23 | registerCli: ReturnType<typeof vi.fn>; |
24 | 24 | registerGatewayMethod: ReturnType<typeof vi.fn>; |
|
| Original file line number | Diff line number | Diff line change |
|---|
@@ -6,7 +6,7 @@ import { resolvePreferredOpenClawTmpDir } from "openclaw/plugin-sdk/temp-path";
|
6 | 6 | |
7 | 7 | const tempRoots = new Set<string>(); |
8 | 8 | |
9 | | -export const logger = { |
| 9 | +const logger = { |
10 | 10 | info() {}, |
11 | 11 | warn() {}, |
12 | 12 | error() {}, |
|
| Original file line number | Diff line number | Diff line change |
|---|
@@ -6,7 +6,7 @@ import { resolvePreferredOpenClawTmpDir } from "openclaw/plugin-sdk/temp-path";
|
6 | 6 | |
7 | 7 | const tempRoots = new Set<string>(); |
8 | 8 | |
9 | | -export const logger = { |
| 9 | +const logger = { |
10 | 10 | info() {}, |
11 | 11 | warn() {}, |
12 | 12 | error() {}, |
|
| Original file line number | Diff line number | Diff line change |
|---|
@@ -3,7 +3,7 @@ import { mkdirSync, mkdtempSync, readFileSync, rmSync, writeFileSync } from "nod
|
3 | 3 | import { join } from "node:path"; |
4 | 4 | import { resolvePreferredOpenClawTmpDir } from "openclaw/plugin-sdk/sandbox"; |
5 | 5 | |
6 | | -export type TranscodeOutcome = |
| 6 | +type TranscodeOutcome = |
7 | 7 | | { ok: true; buffer: Buffer } |
8 | 8 | | { |
9 | 9 | ok: false; |
|
| Original file line number | Diff line number | Diff line change |
|---|
@@ -2,7 +2,7 @@ import type { IncomingMessage, ServerResponse } from "node:http";
|
2 | 2 | import type { Mock } from "vitest"; |
3 | 3 | import { vi } from "vitest"; |
4 | 4 | |
5 | | -export type RegisteredRoute = { |
| 5 | +type RegisteredRoute = { |
6 | 6 | path: string; |
7 | 7 | accountId: string; |
8 | 8 | handler: (req: IncomingMessage, res: ServerResponse) => Promise<void>; |
|
| Original file line number | Diff line number | Diff line change |
|---|
@@ -8,7 +8,7 @@ import {
|
8 | 8 | type FixedWindowRateLimiter, |
9 | 9 | } from "openclaw/plugin-sdk/webhook-ingress"; |
10 | 10 | |
11 | | -export type DmAuthorizationResult = |
| 11 | +type DmAuthorizationResult = |
12 | 12 | | { allowed: true } |
13 | 13 | | { allowed: false; reason: "disabled" | "allowlist-empty" | "not-allowlisted" }; |
14 | 14 | |
|
| Original file line number | Diff line number | Diff line change |
|---|
|
1 | 1 | import { EventEmitter } from "node:events"; |
2 | 2 | import type { IncomingMessage, ServerResponse } from "node:http"; |
3 | 3 | |
4 | | -export function makeBaseReq( |
| 4 | +function makeBaseReq( |
5 | 5 | method: string, |
6 | 6 | opts: { headers?: Record<string, string>; url?: string } = {}, |
7 | 7 | ): IncomingMessage & { destroyed: boolean } { |
|
| Original file line number | Diff line number | Diff line change |
|---|
@@ -30,7 +30,7 @@ const webhooksPluginConfigSchema = z
|
30 | 30 | |
31 | 31 | export type WebhookSecretInput = z.infer<typeof secretInputSchema>; |
32 | 32 | |
33 | | -export type ConfiguredWebhookRouteConfig = { |
| 33 | +type ConfiguredWebhookRouteConfig = { |
34 | 34 | routeId: string; |
35 | 35 | path: string; |
36 | 36 | sessionKey: string; |
|
此内容由惯性聚合(RSS阅读器)自动聚合整理,仅供阅读参考。 原文来自 — 版权归原作者所有。