mirror of
https://github.com/NodeBB/NodeBB.git
synced 2025-11-16 02:36:16 +01:00
refactor(api): post move to write API
This commit is contained in:
@@ -46,7 +46,7 @@ Assert.topic = helpers.try(async (req, res, next) => {
|
||||
|
||||
Assert.post = helpers.try(async (req, res, next) => {
|
||||
if (!await posts.exists(req.params.pid)) {
|
||||
return controllerHelpers.formatApiResponse(404, res, new Error('[[error:no-topic]]'));
|
||||
return controllerHelpers.formatApiResponse(404, res, new Error('[[error:no-post]]'));
|
||||
}
|
||||
|
||||
next();
|
||||
|
||||
Reference in New Issue
Block a user