MCPcopy Index your code
hub / github.com/cursor/community-plugins / drainBaseUrl

Function drainBaseUrl

apps/cursor/src/lib/plugins/queue.ts:69–75  ·  view source on GitHub ↗
()

Source from the content-addressed store, hash-verified

67const DRAIN_PATH = "/api/queue/plugin-scans/drain";
68
69function drainBaseUrl(): string {
70 // VERCEL_URL is set on every Vercel deployment (production & preview).
71 // Local dev falls back to NEXT_PUBLIC_APP_URL, which the rest of the app
72 // already uses for absolute URLs.
73 if (process.env.VERCEL_URL) return `https://${process.env.VERCEL_URL}`;
74 return process.env.NEXT_PUBLIC_APP_URL ?? "http://localhost:3000";
75}
76
77/**
78 * Fire a non-blocking GET at the drain route after the response has been

Callers 1

kickDrainAfterResponseFunction · 0.85

Calls

no outgoing calls

Tested by

no test coverage detected