1
0
mirror of https://github.com/matrix-org/matrix-js-sdk.git synced 2025-08-18 05:42:00 +03:00
This commit is contained in:
David Baker
2015-07-15 19:26:52 +01:00
parent a89de9754f
commit 13f72e1df2

View File

@@ -935,13 +935,13 @@ MatrixClient.prototype.login = function(loginType, data, callback) {
MatrixClient.prototype.register = function(username, password,
session_id, auth, callback) {
if (auth === undefined) { auth = {}; }
if (session_id) auth.session = session_id;
if (session_id) { auth.session = session_id; }
var params = {
auth: auth
};
if (username !== undefined) params.username = username;
if (password !== undefined ) params.password = password;
if (username !== undefined) { params.username = username; }
if (password !== undefined) { params.password = password; }
return this._http.requestWithPrefix(
callback, "POST", "/register", undefined,