Spaces:
Running
Running
Reupload OmniDev clean version
Browse files- app/api/augment/route.ts +2 -1
app/api/augment/route.ts
CHANGED
|
@@ -159,7 +159,8 @@ export async function POST(req: NextRequest) {
|
|
| 159 |
|
| 160 |
const cleaned = cleanText(text);
|
| 161 |
if (!cleaned) {
|
| 162 |
-
|
|
|
|
| 163 |
}
|
| 164 |
|
| 165 |
let json: any;
|
|
|
|
| 159 |
|
| 160 |
const cleaned = cleanText(text);
|
| 161 |
if (!cleaned) {
|
| 162 |
+
const title = instruction.match(/Title:\s*(.*)/)?.[1] || "OmniDev App";
|
| 163 |
+
return NextResponse.json({ ok: true, files: generateFallbackFiles(framework, language, title) } as AugmentResponse, { status: 200 });
|
| 164 |
}
|
| 165 |
|
| 166 |
let json: any;
|