Skip to content
This repository has been archived by the owner on Sep 11, 2024. It is now read-only.

Set the device_id on pre-login MatrixClient #358

Merged
merged 1 commit into from
Jul 21, 2016

Conversation

richvdh
Copy link
Member

@richvdh richvdh commented Jul 20, 2016

In order that device_id is set when we register a new user (or, for that
matter, when we register as a guest), we need to make sure that device_id is
set on the temporary MatrixClient which is created before the user is logged
in - ie, that created by replaceUsingUrls.

In order to achieve this, I've basically removed the distinction between
replaceUsingAccessToken and replaceUsingUrls. There is a side-effect in that
the temporary MatrixClient now gets an e2e sessionStore, but I don't think that
is a bad thing (though it does mean we need matrix-org/matrix-js-sdk#151 to avoid blowing up the js-sdk).

In order that device_id is set when we register a new user (or, for that
matter, when we register as a guest), we need to make sure that device_id is
set on the temporary MatrixClient which is created before the user is logged
in - ie, that created by replaceUsingUrls.

In order to achieve this, I've basically removed the distinction between
replaceUsingAccessToken and replaceUsingUrls. There is a side-effect in that
the temporary MatrixClient now gets an e2e sessionStore, but I don't think that
is a bad thing.
@dbkr
Copy link
Member

dbkr commented Jul 21, 2016

hooray :)

@dbkr dbkr merged commit 46a2c74 into develop Jul 21, 2016
@richvdh richvdh deleted the rav/device_id_for_register branch July 22, 2016 09:09
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants