From f9530f614ceeb87462459a287c93b79026d69c1e Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?=E8=8B=8F=E5=B0=B9=E5=B2=9A?= <770236076@qq.com> Date: Wed, 23 Sep 2020 15:07:45 +0800 Subject: [PATCH] =?UTF-8?q?test=E7=99=BB=E5=BD=95?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- business/auth2/authprovider/weixin/weixin.go | 6 ++++++ business/auth2/authprovider/weixin/weixin_mini.go | 4 ---- 2 files changed, 6 insertions(+), 4 deletions(-) diff --git a/business/auth2/authprovider/weixin/weixin.go b/business/auth2/authprovider/weixin/weixin.go index a1876c258..2f4b344a9 100644 --- a/business/auth2/authprovider/weixin/weixin.go +++ b/business/auth2/authprovider/weixin/weixin.go @@ -27,6 +27,7 @@ var ( AutherObjWX *Auther AutherObjMP *Auther AutherObjNative *Auther + AutherObjApp *Auther ) var ( @@ -48,6 +49,11 @@ func init() { authType: AuthTypeWXNative, } auth2.RegisterAuther(AuthTypeWXNative, AutherObjNative) + + AutherObjApp = &Auther{ + authType: AuthTypeWxApp, + } + auth2.RegisterAuther(AuthTypeWxApp, AutherObjApp) } func (a *Auther) VerifySecret(id, secret string) (authBindEx *auth2.AuthBindEx, err error) { diff --git a/business/auth2/authprovider/weixin/weixin_mini.go b/business/auth2/authprovider/weixin/weixin_mini.go index b6b31715f..072ea9573 100644 --- a/business/auth2/authprovider/weixin/weixin_mini.go +++ b/business/auth2/authprovider/weixin/weixin_mini.go @@ -27,15 +27,11 @@ var ( var ( AutherObjMini *MiniAuther - AutherObjApp *MiniAuther ) func init() { AutherObjMini = new(MiniAuther) auth2.RegisterAuther(AuthTypeMini, AutherObjMini) - - AutherObjApp = new(MiniAuther) - auth2.RegisterAuther(AuthTypeWxApp, AutherObjApp) } func (a *MiniAuther) VerifySecret(dummy, jsCode string) (authBindEx *auth2.AuthBindEx, err error) {