MCPcopy
hub / github.com/simstudioai/sim / docNotReadyResponse

Function docNotReadyResponse

apps/sim/lib/uploads/utils/servable-file-response.ts:12–23  ·  view source on GitHub ↗
(error: unknown)

Source from the content-addressed store, hash-verified

10 * and user-facing copy stay identical instead of being re-typed per route.
11 */
12export function docNotReadyResponse(error: unknown): NextResponse | null {
13 if (error instanceof DocCompileUserError) {
14 return NextResponse.json(
15 {
16 success: false,
17 error: 'A document is still being generated. Wait for it to finish, then try again.',
18 },
19 { status: 409 }
20 )
21 }
22 return null
23}

Callers 15

route.tsFile · 0.90
route.tsFile · 0.90
route.tsFile · 0.90
route.tsFile · 0.90
route.tsFile · 0.90
route.tsFile · 0.90
route.tsFile · 0.90
route.tsFile · 0.90
route.tsFile · 0.90
route.tsFile · 0.90
route.tsFile · 0.90
route.tsFile · 0.90

Calls

no outgoing calls

Tested by

no test coverage detected