Fix eslint + istanbul

This commit is contained in:
Sébastien Chopin 2017-03-28 16:28:24 +02:00
parent f6a02a1ac6
commit d576dad069
2 changed files with 4 additions and 4 deletions

View File

@ -13,14 +13,13 @@ function getModule (filename) {
}
function getModuleNamespace (storeData, namePath) {
if (namePath.length == 1) return storeData.modules
if (namePath.length === 1) {
return storeData.modules
}
let namespace = namePath.shift()
storeData.modules[namespace] = storeData.modules[namespace] || {}
storeData.modules[namespace].namespaced = true
storeData.modules[namespace].modules = storeData.modules[namespace].modules || {}
return getModuleNamespace(storeData.modules[namespace], namePath)
}

View File

@ -71,6 +71,7 @@ export function render (req, res) {
return html
})
.catch((err) => {
/* istanbul ignore if */
if (context.redirected) {
console.error(err) // eslint-disable-line no-console
return err