调整微信小程序的报错。
This commit is contained in:
7
App.vue
7
App.vue
@@ -150,12 +150,14 @@
|
||||
},
|
||||
onShow: function() {
|
||||
console.log('App Show')
|
||||
|
||||
// 每次应用显示时同步用户信息(解决store初始化时uni未准备好导致的问题)
|
||||
try {
|
||||
mutations.syncUserInfoFromStorage();
|
||||
} catch (e) {
|
||||
console.warn('[App] 同步用户信息失败:', e);
|
||||
// 静默失败
|
||||
}
|
||||
|
||||
// 每次应用显示时也检查当前页面是否需要登录
|
||||
this.checkCurrentPageLogin()
|
||||
},
|
||||
@@ -165,6 +167,9 @@
|
||||
this.stopTabBarMonitor();
|
||||
// #endif
|
||||
},
|
||||
onError: function(msg) {
|
||||
console.error('[App Global Error]:', msg);
|
||||
},
|
||||
methods: {
|
||||
|
||||
|
||||
|
||||
Reference in New Issue
Block a user