From a7a03ed148a36c0017dcecfbc17bafe4af6d69fe Mon Sep 17 00:00:00 2001 From: Thunf <458859360@qq.com> Date: Thu, 4 Jan 2018 19:15:05 +0800 Subject: [PATCH 1/2] =?UTF-8?q?fix:=20=E6=94=AF=E4=BB=98=E5=AE=9D=E5=B0=8F?= =?UTF-8?q?=E7=A8=8B=E5=BA=8F=E8=B0=83=E7=94=A8getAuthCode=E6=97=B6?= =?UTF-8?q?=EF=BC=8C=E9=9C=80=E8=A6=81=E8=AE=BE=E7=BD=AEscopes=E5=8F=82?= =?UTF-8?q?=E6=95=B0=E4=B8=BAauth=5Fuser=EF=BC=8C=E4=B8=BA=E4=BA=86?= =?UTF-8?q?=E5=B0=BD=E5=8F=AF=E8=83=BD=E6=8A=B9=E5=B9=B3wepy.login?= =?UTF-8?q?=E6=96=B9=E6=B3=95=E5=9C=A8=E6=94=AF=E4=BB=98=E5=AE=9D=E4=B8=8B?= =?UTF-8?q?=E5=8C=BA=E5=88=AB=E4=B8=8E=E5=BE=AE=E4=BF=A1=E7=9A=84=E5=9C=B0?= =?UTF-8?q?=E6=96=B9=EF=BC=8C=E9=9C=80=E8=A6=81=E5=8A=A0=E4=B8=8A=E8=AF=A5?= =?UTF-8?q?FIX?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- packages/wepy-ant/src/app.js | 3 +++ 1 file changed, 3 insertions(+) diff --git a/packages/wepy-ant/src/app.js b/packages/wepy-ant/src/app.js index cb6411cd6..38e6179e5 100644 --- a/packages/wepy-ant/src/app.js +++ b/packages/wepy-ant/src/app.js @@ -134,6 +134,9 @@ export default class { if (key === 'request') { obj = (typeof(obj) === 'string') ? {url: obj} : obj; } + if (key === 'getAuthCode') { + obj.scopes = 'auth_user' + } if (typeof obj === 'string') { return my[key](obj); } From 54748f8a72f10e76fbb222d1ae31798d7f842f23 Mon Sep 17 00:00:00 2001 From: Thunf <458859360@qq.com> Date: Fri, 5 Jan 2018 11:47:38 +0800 Subject: [PATCH 2/2] =?UTF-8?q?upd:=20=E5=85=81=E8=AE=B8=E7=94=A8=E6=88=B7?= =?UTF-8?q?=E8=A6=86=E7=9B=96my.getAuthCode.scopes=E5=AD=97=E6=AE=B5?= =?UTF-8?q?=E7=9A=84=E5=AE=9A=E4=B9=89=EF=BC=8C=E7=B1=BB=E5=9E=8B=E6=9A=82?= =?UTF-8?q?=E6=97=B6=E4=B8=8D=E9=99=90=E5=88=B6?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- packages/wepy-ant/src/app.js | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/packages/wepy-ant/src/app.js b/packages/wepy-ant/src/app.js index 38e6179e5..3a89c16cb 100644 --- a/packages/wepy-ant/src/app.js +++ b/packages/wepy-ant/src/app.js @@ -135,7 +135,7 @@ export default class { obj = (typeof(obj) === 'string') ? {url: obj} : obj; } if (key === 'getAuthCode') { - obj.scopes = 'auth_user' + obj.scopes = obj.scopes || 'auth_user' } if (typeof obj === 'string') { return my[key](obj);