mirror of
https://github.com/openclaw/openclaw.git
synced 2026-07-10 00:11:19 +00:00
refactor(extensions): remove unused helper exports
This commit is contained in:
parent
4560597c4b
commit
1eaace70e3
6 changed files with 0 additions and 20 deletions
|
|
@ -11,7 +11,6 @@ import {
|
|||
resolveBrowserConfig,
|
||||
resolveManagedBrowserHeadlessMode,
|
||||
resolveProfile,
|
||||
shouldStartLocalBrowserServer,
|
||||
} from "./config.js";
|
||||
import { getBrowserProfileCapabilities } from "./profile-capabilities.js";
|
||||
|
||||
|
|
@ -47,7 +46,6 @@ describe("browser config", () => {
|
|||
expect(resolved.enabled).toBe(true);
|
||||
expect(resolved.controlPort).toBe(18791);
|
||||
expect(resolved.color).toBe("#FF4500");
|
||||
expect(shouldStartLocalBrowserServer(resolved)).toBe(true);
|
||||
expect(resolved.cdpHost).toBe("127.0.0.1");
|
||||
expect(resolved.cdpProtocol).toBe("http");
|
||||
const profile = resolveProfile(resolved, resolved.defaultProfile);
|
||||
|
|
|
|||
|
|
@ -655,8 +655,3 @@ export function getManagedBrowserMissingDisplayError(
|
|||
`Set ${OPENCLAW_BROWSER_HEADLESS_ENV}=1, remove the headed override, or launch under Xvfb.`
|
||||
);
|
||||
}
|
||||
|
||||
/** Return whether local browser control should start for a resolved config. */
|
||||
export function shouldStartLocalBrowserServer(_resolved: unknown) {
|
||||
return true;
|
||||
}
|
||||
|
|
|
|||
|
|
@ -54,7 +54,6 @@ vi.mock("./notify.js", () => ({
|
|||
armPairNotifyOnce: vi.fn(async () => false),
|
||||
formatPendingRequests: vi.fn(() => "No pending device pairing requests."),
|
||||
handleNotifyCommand: vi.fn(async () => ({ text: "notify" })),
|
||||
registerPairingNotifierService: vi.fn(),
|
||||
}));
|
||||
|
||||
import {
|
||||
|
|
|
|||
|
|
@ -482,7 +482,3 @@ export function createPairingNotifierService(api: OpenClawPluginApi): OpenClawPl
|
|||
},
|
||||
};
|
||||
}
|
||||
|
||||
export function registerPairingNotifierService(api: OpenClawPluginApi): void {
|
||||
api.registerService(createPairingNotifierService(api));
|
||||
}
|
||||
|
|
|
|||
|
|
@ -236,13 +236,6 @@ export function createEventDispatcher(account: ResolvedFeishuAccount): Lark.Even
|
|||
});
|
||||
}
|
||||
|
||||
/**
|
||||
* Get a cached client for an account (if exists).
|
||||
*/
|
||||
export function getFeishuClient(accountId: string): Lark.Client | null {
|
||||
return clientCache.get(accountId)?.client ?? null;
|
||||
}
|
||||
|
||||
/**
|
||||
* Clear client cache for a specific account or all accounts.
|
||||
*/
|
||||
|
|
|
|||
|
|
@ -144,7 +144,6 @@ vi.mock("./client.js", () => {
|
|||
start: vi.fn(),
|
||||
})),
|
||||
createEventDispatcher: createEventDispatcherMock,
|
||||
getFeishuClient: vi.fn(() => null),
|
||||
getFeishuUserAgent: vi.fn(() => "openclaw-feishu-test"),
|
||||
pluginVersion: "test",
|
||||
setFeishuClientRuntimeForTest: vi.fn(),
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue