Skip to content

Commit

Permalink
修复手机登录api (#885)
Browse files Browse the repository at this point in the history
contrycode="86"属性应该在手机登录判断下,之前被错误放置到其余登录方式判断下
  • Loading branch information
zhangwenxuan322 committed Oct 13, 2020
1 parent 70ee83b commit 6d9766a
Showing 1 changed file with 1 addition and 2 deletions.
3 changes: 1 addition & 2 deletions NEMbox/api.py
Original file line number Diff line number Diff line change
Expand Up @@ -376,7 +376,7 @@ def login(self, username, password):
self.session.cookies.load()
if username.isdigit():
path = "/weapi/login/cellphone"
params = dict(phone=username, password=password, rememberLogin="true")
params = dict(phone=username, password=password, countrycode="86", rememberLogin="true")
else:
# magic token for login
# see https://github.com/Binaryify/NeteaseCloudMusicApi/blob/master/router/login.js#L15
Expand All @@ -387,7 +387,6 @@ def login(self, username, password):
params = dict(
username=username,
password=password,
countrycode="86",
rememberLogin="true",
clientToken=client_token,
)
Expand Down

0 comments on commit 6d9766a

Please sign in to comment.