Skip to content

Commit

Permalink
feat: add timeout arg
Browse files Browse the repository at this point in the history
  • Loading branch information
yelexin committed Jul 15, 2020
1 parent 2770151 commit afab85b
Show file tree
Hide file tree
Showing 4 changed files with 8 additions and 3 deletions.
3 changes: 2 additions & 1 deletion public/index.html
Original file line number Diff line number Diff line change
Expand Up @@ -103,7 +103,8 @@
user: userGqlEndPoint,
oauth: oauthGqlEndPoint
},
passwordEncPublicKey: undefined
passwordEncPublicKey: undefined,
timeout: 30000
});
</script>
</html>
1 change: 1 addition & 0 deletions src/main.js
Original file line number Diff line number Diff line change
Expand Up @@ -109,6 +109,7 @@ var AuthingGuard = function(clientId, opts) {
GKl64GDcIq3au+aqJQIDAQAB
-----END PUBLIC KEY-----`;

$authing.opts.timeout = opts.timeout || 30000;
$authing.opts.mountId = opts.mountId || null;
// 初始化小程序扫码登录配置
$authing.opts.useSelfWxapp = opts.useSelfWxapp || false;
Expand Down
3 changes: 2 additions & 1 deletion src/views/Profile.vue
Original file line number Diff line number Diff line change
Expand Up @@ -504,7 +504,8 @@ export default {
useSelfWxapp: that.opts.useSelfWxapp,
host: that.opts.host,
accessToken: this.userToken,
passwordEncPublicKey: that.opts.passwordEncPublicKey
passwordEncPublicKey: that.opts.passwordEncPublicKey,
timeout: that.opts.timeout
});
this.$authing = auth;
//已经有资料缓存,可以开始读取
Expand Down
4 changes: 3 additions & 1 deletion src/views/login/index.vue
Original file line number Diff line number Diff line change
Expand Up @@ -385,7 +385,9 @@ export default {
});
this.$authing.pub('authing-unload', err);
},
passwordEncPublicKey: that.opts.passwordEncPublicKey
passwordEncPublicKey: that.opts.passwordEncPublicKey,
timeout: that.opts.timeout
});
let userPoolSettings = await auth.getUserPoolSettings(that.clientId || that.opts.clientId);
Expand Down

0 comments on commit afab85b

Please sign in to comment.