Merge pull request #233 from christianbundy/publish-redirect-latest
Redirect to Latest after publishing new message
This commit is contained in:
commit
6c6c46e4be
@ -536,13 +536,13 @@ router
|
||||
});
|
||||
};
|
||||
ctx.body = await publish({ text, contentWarning });
|
||||
ctx.redirect("/");
|
||||
ctx.redirect("/public/latest");
|
||||
})
|
||||
.post("/publish/custom", koaBody(), async ctx => {
|
||||
const text = String(ctx.request.body.text);
|
||||
const obj = JSON.parse(text);
|
||||
ctx.body = await post.publishCustom(obj);
|
||||
ctx.redirect(`/thread/${encodeURIComponent(ctx.body.key)}`);
|
||||
ctx.redirect(`/public/latest`);
|
||||
})
|
||||
.post("/follow/:feed", koaBody(), async ctx => {
|
||||
const { feed } = ctx.params;
|
||||
|
Loading…
Reference in New Issue
Block a user