手机登录增加验证码登录方式 #1328, #1075 #1227

This commit is contained in:
binaryify
2021-08-20 10:14:36 +08:00
parent ced768962a
commit 077a347d41
5 changed files with 21 additions and 6 deletions
+5 -3
View File
@@ -7,9 +7,11 @@ module.exports = async (query, request) => {
const data = {
phone: query.phone,
countrycode: query.countrycode || '86',
password:
query.md5_password ||
crypto.createHash('md5').update(query.password).digest('hex'),
captcha: query.captcha,
[query.captcha ? 'captcha' : 'password']: query.captcha
? query.captcha
: query.md5_password ||
crypto.createHash('md5').update(query.password).digest('hex'),
rememberLogin: 'true',
}
let result = await request(