if post is not found go to 404

This commit is contained in:
barisusakli
2016-05-13 10:47:01 +03:00
parent 9685290658
commit bf3f19253f

View File

@@ -12,7 +12,7 @@ postsController.redirectToPost = function(req, res, callback) {
}
posts.generatePostPath(pid, req.uid, function(err, path) {
if (err) {
if (err || !path) {
return callback(err);
}