matrix-org/matrix-android-sdk

Register fail

blackchy opened this issue · 1 comments

HomeServerConnectionConfig hsConfig = new HomeServerConnectionConfig(Uri.parse("https://matrix.org"));
RegistrationParams params = new RegistrationParams();
params.username = "UserTest003";
params.password = "1234qwer";
new LoginRestClient(hsConfig).register(params, apiCallback);

Returned a matrix error without errorcode and errorinfo,but has a http error 'mReason: Unauthenticated,mStatus: 401'.
'new LoginRestClient(hsConfig).login(...)' is normal.
Why is it?

The problem has been solved.'params' need a parameter 'type' in map ‘auth’.