Merge branch 'krille/fix-direct-chats' into 'master'

Fix direct chats

See merge request famedly/famedlysdk!360
This commit is contained in:
Sorunome 2020-06-25 06:59:03 +00:00
commit ad67a5abdb
2 changed files with 2 additions and 5 deletions

View file

@ -935,9 +935,8 @@ class Room {
directChats[userID] = [id]; directChats[userID] = [id];
} }
await client.api.setRoomAccountData( await client.api.setAccountData(
client.userID, client.userID,
id,
'm.direct', 'm.direct',
directChats, directChats,
); );

View file

@ -1827,9 +1827,7 @@ class FakeMatrixApi extends MockClient {
(var reqI) => { (var reqI) => {
'event_id': '42', 'event_id': '42',
}, },
'/client/r0/user/%40test%3AfakeServer.notExisting/rooms/%211234%3AfakeServer.notExisting/account_data/m.direct': '/client/r0/user/%40test%3AfakeServer.notExisting/account_data/m.direct':
(var reqI) => {},
'/client/r0/user/%40test%3AfakeServer.notExisting/rooms/%21localpart%3Aserver.abc/account_data/m.direct':
(var reqI) => {}, (var reqI) => {},
'/client/r0/directory/list/room/!localpart%3Aexample.com': (var req) => '/client/r0/directory/list/room/!localpart%3Aexample.com': (var req) =>
{}, {},