提交 7d8e570d 编写于 作者: Q qiang

fix: isTabBarPage

上级 4251ebf7
...@@ -24,7 +24,7 @@ function getTabBarPages (appJson) { ...@@ -24,7 +24,7 @@ function getTabBarPages (appJson) {
} }
function isTabBarPage (pathName, tabBarPages) { function isTabBarPage (pathName, tabBarPages) {
return tabBarPages && tabBarPages.find(item => item.pagePath === pathName) return Array.isArray(tabBarPages) && tabBarPages.find(item => item.pagePath === pathName)
} }
function parseEntryPagePath (appJson, manifestJson) { function parseEntryPagePath (appJson, manifestJson) {
...@@ -89,7 +89,7 @@ module.exports = function (appJson, manifestJson, { ...@@ -89,7 +89,7 @@ module.exports = function (appJson, manifestJson, {
path: entryPagePath + '.js' + (appJson.entryPageQuery || '') path: entryPagePath + '.js' + (appJson.entryPageQuery || '')
} }
const tabBar = manifestJson.plus.tabBar const tabBar = manifestJson.plus.tabBar
if (isTabBarPage(entryPagePath, tabBar.list)) { if (tabBar && isTabBarPage(entryPagePath, tabBar.list)) {
tabBar.child = ['lauchwebview'] tabBar.child = ['lauchwebview']
} }
} else { } else {
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册