diff --git a/packages/server/src/api/controllers/view/utils.js b/packages/server/src/api/controllers/view/utils.js index 7b5bad46b4..cdb55aed81 100644 --- a/packages/server/src/api/controllers/view/utils.js +++ b/packages/server/src/api/controllers/view/utils.js @@ -25,7 +25,9 @@ exports.getView = async viewName => { return viewDoc.view } catch (err) { // Return null when PouchDB doesn't found the view - if (err.status === 404) return null + if (err.status === 404) { + return null + } throw err }