style: apply oxfmt

This commit is contained in:
Peter Steinberger
2026-01-17 18:32:15 +00:00
parent 7a3fa9ce03
commit 534a012a4e
6 changed files with 11 additions and 15 deletions

View File

@@ -114,9 +114,7 @@ export async function gatherDaemonStatus(
const [loaded, command, runtime] = await Promise.all([
service.isLoaded({ env: process.env }).catch(() => false),
service.readCommand(process.env).catch(() => null),
service
.readRuntime(process.env)
.catch((err) => ({ status: "unknown", detail: String(err) })),
service.readRuntime(process.env).catch((err) => ({ status: "unknown", detail: String(err) })),
]);
const configAudit = await auditGatewayServiceConfig({
env: process.env,

View File

@@ -55,9 +55,7 @@ describe("memory cli", () => {
expect(log).toHaveBeenCalledWith(expect.stringContaining("Vector: ready"));
expect(log).toHaveBeenCalledWith(expect.stringContaining("Vector dims: 1024"));
expect(log).toHaveBeenCalledWith(
expect.stringContaining("Vector path: /opt/sqlite-vec.dylib"),
);
expect(log).toHaveBeenCalledWith(expect.stringContaining("Vector path: /opt/sqlite-vec.dylib"));
});
it("prints vector error when unavailable", async () => {

View File

@@ -177,8 +177,7 @@ const FIELD_LABELS: Record<string, string> = {
"agents.defaults.memorySearch.local.modelPath": "Local Embedding Model Path",
"agents.defaults.memorySearch.store.path": "Memory Search Index Path",
"agents.defaults.memorySearch.store.vector.enabled": "Memory Search Vector Index",
"agents.defaults.memorySearch.store.vector.extensionPath":
"Memory Search Vector Extension Path",
"agents.defaults.memorySearch.store.vector.extensionPath": "Memory Search Vector Extension Path",
"agents.defaults.memorySearch.chunking.tokens": "Memory Chunk Tokens",
"agents.defaults.memorySearch.chunking.overlap": "Memory Chunk Overlap Tokens",
"agents.defaults.memorySearch.sync.onSessionStart": "Index on Session Start",

View File

@@ -17,7 +17,8 @@ export async function isWSL(): Promise<boolean> {
}
try {
const release = await fs.readFile("/proc/sys/kernel/osrelease", "utf8");
wslCached = release.toLowerCase().includes("microsoft") || release.toLowerCase().includes("wsl");
wslCached =
release.toLowerCase().includes("microsoft") || release.toLowerCase().includes("wsl");
} catch {
wslCached = false;
}

View File

@@ -105,9 +105,7 @@ function formatConsoleTimestamp(style: ConsoleStyle): string {
}
function hasTimestampPrefix(value: string): boolean {
return /^(?:\d{2}:\d{2}:\d{2}|\d{4}-\d{2}-\d{2}T\d{2}:\d{2}:\d{2}(?:\.\d+)?Z?)/.test(
value,
);
return /^(?:\d{2}:\d{2}:\d{2}|\d{4}-\d{2}-\d{2}T\d{2}:\d{2}:\d{2}(?:\.\d+)?Z?)/.test(value);
}
function isJsonPayload(value: string): boolean {

View File

@@ -161,8 +161,9 @@ function normalizeForwardedUserLabel(user: TelegramForwardUser) {
const username = user.username?.trim() || undefined;
const id = user.id != null ? String(user.id) : undefined;
const display =
(name && username ? `${name} (@${username})` : name || (username ? `@${username}` : undefined)) ||
(id ? `user:${id}` : undefined);
(name && username
? `${name} (@${username})`
: name || (username ? `@${username}` : undefined)) || (id ? `user:${id}` : undefined);
return { display, name: name || undefined, username, id };
}
@@ -213,7 +214,8 @@ function buildForwardedContextFromChat(params: {
type: string;
signature?: string;
}): TelegramForwardedContext | null {
const fallbackKind = params.type === "channel" || params.type === "legacy_channel" ? "channel" : "chat";
const fallbackKind =
params.type === "channel" || params.type === "legacy_channel" ? "channel" : "chat";
const { display, title, username, id } = normalizeForwardedChatLabel(params.chat, fallbackKind);
if (!display) return null;
const signature = params.signature?.trim() || undefined;