diff --git a/src/index.ts b/src/index.ts index bde4505..a35456d 100644 --- a/src/index.ts +++ b/src/index.ts @@ -335,12 +335,14 @@ export default function killTheNewsletter(

` ) ); + const feedId = database.run( sql`INSERT INTO "feeds" ("title") VALUES (${req.body.name})` ).lastInsertRowid; const entry = database.get<{ title: string; content: HTML }>( sql`SELECT "title", "content" FROM "entries" WHERE "feed" = ${feedId}` )!; + res.send( layout(html`

${entry.title}