style: format gmail hooks and tools

This commit is contained in:
Peter Steinberger
2025-12-24 23:09:31 +01:00
parent 3bb5baa6d2
commit 88b92a9605
3 changed files with 4 additions and 4 deletions

View File

@@ -150,7 +150,7 @@ function normalizeToolParameters(tool: AnyAgentTool): AnyAgentTool {
properties:
Object.keys(mergedProperties).length > 0
? mergedProperties
: schema.properties ?? {},
: (schema.properties ?? {}),
...(mergedRequired && mergedRequired.length > 0
? { required: mergedRequired }
: {}),

View File

@@ -145,13 +145,13 @@ export async function runGmailSetup(opts: GmailSetupOptions) {
const servePath = normalizeServePath(
tailscaleMode !== "off" && !configuredServePath
? "/"
: configuredServePath ?? DEFAULT_GMAIL_SERVE_PATH,
: (configuredServePath ?? DEFAULT_GMAIL_SERVE_PATH),
);
const tailscalePath = normalizeServePath(
opts.tailscalePath ??
baseConfig.hooks?.gmail?.tailscale?.path ??
(tailscaleMode !== "off"
? configuredServePath ?? DEFAULT_GMAIL_SERVE_PATH
? (configuredServePath ?? DEFAULT_GMAIL_SERVE_PATH)
: servePath),
);

View File

@@ -170,7 +170,7 @@ export function resolveGmailHookRuntimeConfig(
? hasExplicitServePath
? servePathRaw
: DEFAULT_GMAIL_SERVE_PATH
: tailscalePathRaw ?? servePath,
: (tailscalePathRaw ?? servePath),
);
return {