From 0c39d469c1a50bc3f8a86ed79f768035c6c8c690 Mon Sep 17 00:00:00 2001 From: aixianling Date: Mon, 13 Jun 2022 20:24:30 +0800 Subject: [PATCH] =?UTF-8?q?=E4=BA=A7=E5=93=81=E5=BA=93=E5=A2=9E=E5=8A=A0?= =?UTF-8?q?=E4=BC=81=E5=BE=AE=E7=AB=AF=E7=99=BB=E5=BD=95,=E7=99=BB?= =?UTF-8?q?=E5=BD=95=E4=BF=AE=E5=A4=8D?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- src/pages/login.vue | 10 ++++++---- 1 file changed, 6 insertions(+), 4 deletions(-) diff --git a/src/pages/login.vue b/src/pages/login.vue index 15437a73..acd17344 100644 --- a/src/pages/login.vue +++ b/src/pages/login.vue @@ -87,11 +87,13 @@ export default { } let {code} = this.$route.query this.getToken({code}).then(token => { - this.login(token) - if (module != 'AppCountryAlbum') { - this.getAccount({module}) + if (token) { + this.login(token) + if (module != 'AppCountryAlbum') { + this.getAccount({module}) + } + this.target ? uni.reLaunch({url: this.target}) : uni.navigateBack({}) } - this.target ? uni.reLaunch({url: this.target}) : uni.navigateBack({}) }).catch(err => { this.err = err })