fix: Change password using email authentication

This commit is contained in:
Krille Fear 2022-02-19 13:36:56 +01:00
parent 9808e3fc0a
commit ecc60efea9
3 changed files with 6 additions and 4 deletions

View File

@ -1,3 +1,6 @@
## [0.8.11] - 19nd Feb 2022
- fix: Change password using email authentication
## [0.8.10] - 19nd Feb 2022
- chore: Increase default thumbnail size to 800
- fix: sortRooms should be triggered right before onSync is called

View File

@ -2232,9 +2232,8 @@ class Client extends MatrixApi {
AuthenticationData? auth,
bool? logoutDevices}) async {
final userID = this.userID;
if (userID == null) return;
try {
if (oldPassword != null) {
if (oldPassword != null && userID != null) {
auth = AuthenticationPassword(
identifier: AuthenticationUserIdentifier(user: userID),
password: oldPassword,
@ -2252,7 +2251,7 @@ class Client extends MatrixApi {
false)) {
rethrow;
}
if (oldPassword == null) {
if (oldPassword == null || userID == null) {
rethrow;
}
return changePassword(

View File

@ -1,6 +1,6 @@
name: matrix
description: Matrix Dart SDK
version: 0.8.10
version: 0.8.11
homepage: https://famedly.com
repository: https://gitlab.com/famedly/company/frontend/famedlysdk.git