diff --git a/src/components/views/rooms/NewRoomIntro.tsx b/src/components/views/rooms/NewRoomIntro.tsx
index 6dd25b6bca..56c7d7224c 100644
--- a/src/components/views/rooms/NewRoomIntro.tsx
+++ b/src/components/views/rooms/NewRoomIntro.tsx
@@ -55,10 +55,10 @@ const NewRoomIntro = () => {
? room.targets[0]?.userId
: DMRoomMap.shared().getUserIdForRoomId(roomId);
- let body;
+ let body: JSX.Element;
if (dmPartner) {
let introMessage = _t("This is the beginning of your direct message history with .");
- let caption;
+ let caption: string | undefined;
if (isLocalRoom) {
introMessage = _t("Send your first message to invite to chat");
@@ -67,7 +67,7 @@ const NewRoomIntro = () => {
}
const member = room?.getMember(dmPartner);
- const displayName = member?.rawDisplayName || dmPartner;
+ const displayName = room?.name || member?.rawDisplayName || dmPartner;
body = {
describe("for a DM Room", () => {
beforeEach(() => {
jest.spyOn(DMRoomMap.shared(), "getUserIdForRoomId").mockReturnValue(userId);
- renderNewRoomIntro(client, new Room(roomId, client, client.getUserId()));
+ const room = new Room(roomId, client, client.getUserId());
+ room.name = "test_room";
+ renderNewRoomIntro(client, room);
});
it("should render the expected intro", () => {
- const expected = `This is the beginning of your direct message history with ${userId}.`;
- screen.getByText((id, element) => element.tagName === "SPAN" && element.textContent === expected);
+ const expected = `This is the beginning of your direct message history with test_room.`;
+ screen.getByText((id, element) => element?.tagName === "SPAN" && element?.textContent === expected);
});
});
@@ -66,13 +68,14 @@ describe("NewRoomIntro", () => {
beforeEach(() => {
jest.spyOn(DMRoomMap.shared(), "getUserIdForRoomId").mockReturnValue(userId);
const localRoom = new LocalRoom(roomId, client, client.getUserId());
+ localRoom.name = "test_room";
localRoom.targets.push(new DirectoryMember({ user_id: userId }));
renderNewRoomIntro(client, localRoom);
});
it("should render the expected intro", () => {
- const expected = `Send your first message to invite ${userId} to chat`;
- screen.getByText((id, element) => element.tagName === "SPAN" && element.textContent === expected);
+ const expected = `Send your first message to invite test_room to chat`;
+ screen.getByText((id, element) => element?.tagName === "SPAN" && element?.textContent === expected);
});
});
});
diff --git a/tsc.txt b/tsc.txt
new file mode 100644
index 0000000000..fc312ae26e
--- /dev/null
+++ b/tsc.txt
@@ -0,0 +1,3547 @@
+node_modules/@matrix-org/olm/index.d.ts(21,5): error TS7010: 'free', which lacks return-type annotation, implicitly has an 'any' return type.
+node_modules/@matrix-org/olm/index.d.ts(22,5): error TS7010: 'create', which lacks return-type annotation, implicitly has an 'any' return type.
+node_modules/@matrix-org/olm/index.d.ts(26,5): error TS7010: 'mark_keys_as_published', which lacks return-type annotation, implicitly has an 'any' return type.
+node_modules/@matrix-org/olm/index.d.ts(28,5): error TS7010: 'generate_one_time_keys', which lacks return-type annotation, implicitly has an 'any' return type.
+node_modules/@matrix-org/olm/index.d.ts(29,5): error TS7010: 'remove_one_time_keys', which lacks return-type annotation, implicitly has an 'any' return type.
+node_modules/@matrix-org/olm/index.d.ts(30,5): error TS7010: 'generate_fallback_key', which lacks return-type annotation, implicitly has an 'any' return type.
+node_modules/@matrix-org/olm/index.d.ts(35,5): error TS7010: 'unpickle', which lacks return-type annotation, implicitly has an 'any' return type.
+node_modules/@matrix-org/olm/index.d.ts(42,5): error TS7010: 'unpickle', which lacks return-type annotation, implicitly has an 'any' return type.
+node_modules/@matrix-org/olm/index.d.ts(70,5): error TS7010: 'unpickle', which lacks return-type annotation, implicitly has an 'any' return type.
+node_modules/@matrix-org/olm/index.d.ts(83,5): error TS7010: 'unpickle', which lacks return-type annotation, implicitly has an 'any' return type.
+node_modules/await-lock/build/AwaitLock.d.ts(5,5): error TS18028: Private identifiers are only available when targeting ECMAScript 2015 and higher.
+node_modules/matrix-events-sdk/lib/NamespacedMap.d.ts(3,35): error TS2344: Type 'Optional' does not satisfy the constraint 'string'.
+ Type 'undefined' is not assignable to type 'string'.
+node_modules/matrix-js-sdk/src/NamespacedValue.ts(30,16): error TS1056: Accessors are only available when targeting ECMAScript 5 and higher.
+node_modules/matrix-js-sdk/src/NamespacedValue.ts(34,9): error TS2322: Type 'U | undefined' is not assignable to type 'S | U'.
+ Type 'undefined' is not assignable to type 'S | U'.
+node_modules/matrix-js-sdk/src/NamespacedValue.ts(37,16): error TS1056: Accessors are only available when targeting ECMAScript 5 and higher.
+node_modules/matrix-js-sdk/src/NamespacedValue.ts(41,9): error TS2322: Type 'U | undefined' is not assignable to type 'S | U | null'.
+ Type 'undefined' is not assignable to type 'S | U | null'.
+node_modules/matrix-js-sdk/src/NamespacedValue.ts(55,14): error TS2454: Variable 'val' is used before being assigned.
+node_modules/matrix-js-sdk/src/NamespacedValue.ts(58,16): error TS2454: Variable 'val' is used before being assigned.
+node_modules/matrix-js-sdk/src/NamespacedValue.ts(81,16): error TS1056: Accessors are only available when targeting ECMAScript 5 and higher.
+node_modules/matrix-js-sdk/src/NamespacedValue.ts(85,9): error TS2322: Type 'U | undefined' is not assignable to type 'S | U'.
+ Type 'undefined' is not assignable to type 'S | U'.
+node_modules/matrix-js-sdk/src/NamespacedValue.ts(102,16): error TS1056: Accessors are only available when targeting ECMAScript 5 and higher.
+node_modules/matrix-js-sdk/src/NamespacedValue.ts(103,9): error TS2322: Type 'U | undefined' is not assignable to type 'U'.
+ 'U' could be instantiated with an arbitrary type which could be unrelated to 'U | undefined'.
+node_modules/matrix-js-sdk/src/NamespacedValue.ts(106,16): error TS1056: Accessors are only available when targeting ECMAScript 5 and higher.
+node_modules/matrix-js-sdk/src/NamespacedValue.ts(107,9): error TS2322: Type 'S | null | undefined' is not assignable to type 'S'.
+ 'S' could be instantiated with an arbitrary type which could be unrelated to 'S | null | undefined'.
+node_modules/matrix-js-sdk/src/ReEmitter.ts(65,35): error TS2345: Argument of type '((...args: any[]) => void) | undefined' is not assignable to parameter of type '(...args: any[]) => void'.
+ Type 'undefined' is not assignable to type '(...args: any[]) => void'.
+node_modules/matrix-js-sdk/src/ToDeviceMessageQueue.ts(31,13): error TS2322: Type 'null' is not assignable to type 'number'.
+node_modules/matrix-js-sdk/src/ToDeviceMessageQueue.ts(45,9): error TS2322: Type 'null' is not assignable to type 'number'.
+node_modules/matrix-js-sdk/src/ToDeviceMessageQueue.ts(64,9): error TS2322: Type 'null' is not assignable to type 'number'.
+node_modules/matrix-js-sdk/src/ToDeviceMessageQueue.ts(89,72): error TS2345: Argument of type 'null' is not assignable to parameter of type 'MatrixEvent'.
+node_modules/matrix-js-sdk/src/ToDeviceMessageQueue.ts(93,32): error TS2571: Object is of type 'unknown'.
+node_modules/matrix-js-sdk/src/ToDeviceMessageQueue.ts(95,65): error TS2532: Object is possibly 'undefined'.
+node_modules/matrix-js-sdk/src/ToDeviceMessageQueue.ts(103,13): error TS2322: Type 'Timeout' is not assignable to type 'number'.
+node_modules/matrix-js-sdk/src/autodiscovery.ts(151,13): error TS2322: Type '{ "m.homeserver": { state: AutoDiscoveryAction; error: string; base_url: null; }; "m.identity_server": { state: AutoDiscoveryAction; error: null; base_url: null; }; }' is not assignable to type 'IClientWellKnown'.
+ The types of '"m.identity_server".error' are incompatible between these types.
+ Type 'null' is not assignable to type 'string | Error | undefined'.
+node_modules/matrix-js-sdk/src/autodiscovery.ts(160,13): error TS2322: Type '{ "m.homeserver": { state: AutoDiscoveryAction; error: string; base_url: null; }; "m.identity_server": { state: AutoDiscoveryAction; error: null; base_url: null; }; }' is not assignable to type 'IClientWellKnown'.
+node_modules/matrix-js-sdk/src/autodiscovery.ts(171,13): error TS2322: Type '{ "m.homeserver": { state: AutoDiscoveryAction; error: string; base_url: null; }; "m.identity_server": { state: AutoDiscoveryAction; error: null; base_url: null; }; }' is not assignable to type 'IClientWellKnown'.
+node_modules/matrix-js-sdk/src/autodiscovery.ts(184,13): error TS2322: Type 'string | true' is not assignable to type 'null'.
+ Type 'string' is not assignable to type 'null'.
+node_modules/matrix-js-sdk/src/autodiscovery.ts(186,13): error TS2322: Type '{ "m.homeserver": { state: AutoDiscoveryAction; error: string; base_url: null; }; "m.identity_server": { state: AutoDiscoveryAction; error: null; base_url: null; }; }' is not assignable to type 'IClientWellKnown'.
+node_modules/matrix-js-sdk/src/autodiscovery.ts(192,13): error TS2322: Type 'null' is not assignable to type 'string'.
+node_modules/matrix-js-sdk/src/autodiscovery.ts(193,13): error TS2322: Type 'string | true' is not assignable to type 'null'.
+ Type 'string' is not assignable to type 'null'.
+node_modules/matrix-js-sdk/src/autodiscovery.ts(234,17): error TS2322: Type 'string | true' is not assignable to type 'null'.
+ Type 'string' is not assignable to type 'null'.
+node_modules/matrix-js-sdk/src/autodiscovery.ts(246,17): error TS2322: Type 'string | true' is not assignable to type 'null'.
+ Type 'string' is not assignable to type 'null'.
+node_modules/matrix-js-sdk/src/autodiscovery.ts(259,21): error TS7053: Element implicitly has an 'any' type because expression of type 'string' can't be used to index type '{ state: AutoDiscoveryAction; error: string; base_url: null; } | { state: AutoDiscoveryAction; error: null; base_url: null; }'.
+ No index signature with a parameter of type 'string' was found on type '{ state: AutoDiscoveryAction; error: string; base_url: null; } | { state: AutoDiscoveryAction; error: null; base_url: null; }'.
+node_modules/matrix-js-sdk/src/autodiscovery.ts(263,17): error TS7053: Element implicitly has an 'any' type because expression of type 'string' can't be used to index type '{ "m.homeserver": { state: AutoDiscoveryAction; error: string; base_url: null; }; "m.identity_server": { state: AutoDiscoveryAction; error: null; base_url: null; }; }'.
+ No index signature with a parameter of type 'string' was found on type '{ "m.homeserver": { state: AutoDiscoveryAction; error: string; base_url: null; }; "m.identity_server": { state: AutoDiscoveryAction; error: null; base_url: null; }; }'.
+node_modules/matrix-js-sdk/src/autodiscovery.ts(268,9): error TS2322: Type '{ "m.homeserver": { state: AutoDiscoveryAction; error: string; base_url: null; }; "m.identity_server": { state: AutoDiscoveryAction; error: null; base_url: null; }; }' is not assignable to type 'IClientWellKnown'.
+node_modules/matrix-js-sdk/src/autodiscovery.ts(328,21): error TS2322: Type 'null' is not assignable to type 'string'.
+node_modules/matrix-js-sdk/src/autodiscovery.ts(336,13): error TS2322: Type '{ "m.homeserver": { state: AutoDiscoveryAction; error: string; base_url: null; }; "m.identity_server": { state: AutoDiscoveryAction; error: null; base_url: null; }; }' is not assignable to type 'IClientWellKnown'.
+ The types of '"m.identity_server".error' are incompatible between these types.
+ Type 'null' is not assignable to type 'string | Error | undefined'.
+node_modules/matrix-js-sdk/src/autodiscovery.ts(443,29): error TS2322: Type 'unknown' is not assignable to type 'string | Error | undefined'.
+node_modules/matrix-js-sdk/src/autodiscovery.ts(446,37): error TS2571: Object is of type 'unknown'.
+node_modules/matrix-js-sdk/src/client.ts(498,5): error TS2411: Property '"og:image"' of type 'string | undefined' is not assignable to 'string' index type 'string | number'.
+node_modules/matrix-js-sdk/src/client.ts(499,5): error TS2411: Property '"og:image:type"' of type 'string | undefined' is not assignable to 'string' index type 'string | number'.
+node_modules/matrix-js-sdk/src/client.ts(500,5): error TS2411: Property '"og:image:height"' of type 'number | undefined' is not assignable to 'string' index type 'string | number'.
+node_modules/matrix-js-sdk/src/client.ts(501,5): error TS2411: Property '"og:image:width"' of type 'number | undefined' is not assignable to 'string' index type 'string | number'.
+node_modules/matrix-js-sdk/src/client.ts(502,5): error TS2411: Property '"og:description"' of type 'string | undefined' is not assignable to 'string' index type 'string | number'.
+node_modules/matrix-js-sdk/src/client.ts(503,5): error TS2411: Property '"matrix:image:size"' of type 'number | undefined' is not assignable to 'string' index type 'string | number'.
+node_modules/matrix-js-sdk/src/client.ts(892,12): error TS2322: Type 'null' is not assignable to type '[number, number, number]'.
+node_modules/matrix-js-sdk/src/client.ts(897,12): error TS2564: Property 'pickleKey' has no initializer and is not definitely assigned in the constructor.
+node_modules/matrix-js-sdk/src/client.ts(904,12): error TS2564: Property 'crypto' has no initializer and is not definitely assigned in the constructor.
+node_modules/matrix-js-sdk/src/client.ts(906,12): error TS2564: Property 'callEventHandler' has no initializer and is not definitely assigned in the constructor.
+node_modules/matrix-js-sdk/src/client.ts(917,15): error TS2322: Type 'null' is not assignable to type 'SyncApi'.
+node_modules/matrix-js-sdk/src/client.ts(920,15): error TS2322: Type 'null' is not assignable to type 'EventTimelineSet'.
+node_modules/matrix-js-sdk/src/client.ts(925,15): error TS2564: Property 'syncApi' has no initializer and is not definitely assigned in the constructor.
+node_modules/matrix-js-sdk/src/client.ts(927,12): error TS2564: Property 'pushRules' has no initializer and is not definitely assigned in the constructor.
+node_modules/matrix-js-sdk/src/client.ts(928,15): error TS2564: Property 'syncLeftRoomsPromise' has no initializer and is not definitely assigned in the constructor.
+node_modules/matrix-js-sdk/src/client.ts(930,15): error TS2564: Property 'clientOpts' has no initializer and is not definitely assigned in the constructor.
+node_modules/matrix-js-sdk/src/client.ts(931,15): error TS2564: Property 'clientWellKnownIntervalID' has no initializer and is not definitely assigned in the constructor.
+node_modules/matrix-js-sdk/src/client.ts(932,15): error TS2564: Property 'canResetTimelineCallback' has no initializer and is not definitely assigned in the constructor.
+node_modules/matrix-js-sdk/src/client.ts(939,15): error TS2564: Property 'serverVersionsPromise' has no initializer and is not definitely assigned in the constructor.
+node_modules/matrix-js-sdk/src/client.ts(941,12): error TS2564: Property 'cachedCapabilities' has no initializer and is not definitely assigned in the constructor.
+node_modules/matrix-js-sdk/src/client.ts(945,15): error TS2564: Property 'clientWellKnown' has no initializer and is not definitely assigned in the constructor.
+node_modules/matrix-js-sdk/src/client.ts(946,15): error TS2564: Property 'clientWellKnownPromise' has no initializer and is not definitely assigned in the constructor.
+node_modules/matrix-js-sdk/src/client.ts(950,15): error TS2564: Property 'exportedOlmDeviceToImport' has no initializer and is not definitely assigned in the constructor.
+node_modules/matrix-js-sdk/src/client.ts(961,54): error TS2345: Argument of type 'string | undefined' is not assignable to parameter of type 'string'.
+ Type 'undefined' is not assignable to type 'string'.
+node_modules/matrix-js-sdk/src/client.ts(965,9): error TS2322: Type 'IIdentityServerProvider | undefined' is not assignable to type 'IIdentityServerProvider'.
+ Type 'undefined' is not assignable to type 'IIdentityServerProvider'.
+node_modules/matrix-js-sdk/src/client.ts(967,9): error TS2322: Type 'boolean | undefined' is not assignable to type 'boolean'.
+node_modules/matrix-js-sdk/src/client.ts(968,9): error TS2322: Type 'IStore | StubStore' is not assignable to type 'IStore'.
+ Type 'StubStore' is not assignable to type 'IStore'.
+ Types of property 'getAccountData' are incompatible.
+ Type '(eventType: string) => MatrixEvent | undefined' is not assignable to type '(eventType: string) => MatrixEvent'.
+node_modules/matrix-js-sdk/src/client.ts(969,9): error TS2322: Type 'string | null' is not assignable to type 'string | undefined'.
+node_modules/matrix-js-sdk/src/client.ts(972,30): error TS2322: Type 'string | null' is not assignable to type 'string | undefined'.
+node_modules/matrix-js-sdk/src/client.ts(978,13): error TS2322: Type '((opts: Pick & { uri: string; method: Method; _matrix_opts: IHttpOpts; }, callback: RequestCallback) => IRequest) | undefined' is not assignable to type '(opts: Pick & { uri: string; method: Method; _matrix_opts: IHttpOpts; }, callback: RequestCallback) => IRequest'.
+ Type 'undefined' is not assignable to type '(opts: Pick & { uri: string; method: Method; _matrix_opts: IHttpOpts; }, callback: RequestCallback) => IRequest'.
+node_modules/matrix-js-sdk/src/client.ts(1009,9): error TS2322: Type 'MatrixScheduler | undefined' is not assignable to type 'MatrixScheduler'.
+ Type 'undefined' is not assignable to type 'MatrixScheduler'.
+node_modules/matrix-js-sdk/src/client.ts(1012,43): error TS2345: Argument of type 'string | undefined' is not assignable to parameter of type 'string'.
+ Type 'undefined' is not assignable to type 'string'.
+node_modules/matrix-js-sdk/src/client.ts(1037,9): error TS2322: Type 'CryptoStore | undefined' is not assignable to type 'CryptoStore'.
+ Type 'undefined' is not assignable to type 'CryptoStore'.
+node_modules/matrix-js-sdk/src/client.ts(1038,9): error TS2322: Type 'string[] | undefined' is not assignable to type 'string[]'.
+ Type 'undefined' is not assignable to type 'string[]'.
+node_modules/matrix-js-sdk/src/client.ts(1062,39): error TS2345: Argument of type 'string | undefined' is not assignable to parameter of type 'string'.
+ Type 'undefined' is not assignable to type 'string'.
+node_modules/matrix-js-sdk/src/client.ts(1072,50): error TS2532: Object is possibly 'undefined'.
+node_modules/matrix-js-sdk/src/client.ts(1075,44): error TS2345: Argument of type 'string | null' is not assignable to parameter of type 'string'.
+ Type 'null' is not assignable to type 'string'.
+node_modules/matrix-js-sdk/src/client.ts(1077,56): error TS2532: Object is possibly 'undefined'.
+node_modules/matrix-js-sdk/src/client.ts(1078,56): error TS2532: Object is possibly 'undefined'.
+node_modules/matrix-js-sdk/src/client.ts(1079,86): error TS2345: Argument of type 'number | undefined' is not assignable to parameter of type 'number'.
+ Type 'undefined' is not assignable to type 'number'.
+node_modules/matrix-js-sdk/src/client.ts(1083,25): error TS2532: Object is possibly 'undefined'.
+node_modules/matrix-js-sdk/src/client.ts(1083,38): error TS2532: Object is possibly 'undefined'.
+node_modules/matrix-js-sdk/src/client.ts(1084,86): error TS2345: Argument of type 'number | undefined' is not assignable to parameter of type 'number'.
+ Type 'undefined' is not assignable to type 'number'.
+node_modules/matrix-js-sdk/src/client.ts(1102,41): error TS2769: No overload matches this call.
+ Overload 1 of 2, '(o: {}): string[]', gave the following error.
+ Argument of type 'unknown' is not assignable to parameter of type '{}'.
+ Overload 2 of 2, '(o: object): string[]', gave the following error.
+ Argument of type 'unknown' is not assignable to parameter of type 'object'.
+node_modules/matrix-js-sdk/src/client.ts(1102,57): error TS2345: Argument of type 'string | null' is not assignable to parameter of type 'string'.
+ Type 'null' is not assignable to type 'string'.
+node_modules/matrix-js-sdk/src/client.ts(1123,47): error TS2345: Argument of type 'string | null' is not assignable to parameter of type 'string'.
+ Type 'null' is not assignable to type 'string'.
+node_modules/matrix-js-sdk/src/client.ts(1188,21): error TS2339: Property 'serverSupport' does not exist on type '{ serverSupport: boolean; stable: boolean; } | null'.
+node_modules/matrix-js-sdk/src/client.ts(1188,36): error TS2339: Property 'stable' does not exist on type '{ serverSupport: boolean; stable: boolean; } | null'.
+node_modules/matrix-js-sdk/src/client.ts(1236,9): error TS2322: Type 'null' is not assignable to type 'SyncApi | SlidingSyncSdk'.
+node_modules/matrix-js-sdk/src/client.ts(1241,9): error TS2322: Type 'null' is not assignable to type 'CallEventHandler'.
+node_modules/matrix-js-sdk/src/client.ts(1243,30): error TS2769: No overload matches this call.
+ Overload 1 of 3, '(intervalId: Timeout): void', gave the following error.
+ Argument of type 'Timeout | null' is not assignable to parameter of type 'Timeout'.
+ Type 'null' is not assignable to type 'Timeout'.
+ Overload 2 of 3, '(intervalId: string | number | Timeout | undefined): void', gave the following error.
+ Argument of type 'Timeout | null' is not assignable to parameter of type 'string | number | Timeout | undefined'.
+ Type 'null' is not assignable to type 'string | number | Timeout | undefined'.
+ Overload 3 of 3, '(id?: number | undefined): void', gave the following error.
+ Argument of type 'Timeout | null' is not assignable to parameter of type 'number | undefined'.
+ Type 'null' is not assignable to type 'number | undefined'.
+node_modules/matrix-js-sdk/src/client.ts(1262,37): error TS2366: Function lacks ending return statement and return type does not include 'undefined'.
+node_modules/matrix-js-sdk/src/client.ts(1268,13): error TS2322: Type 'undefined' is not assignable to type 'string'.
+node_modules/matrix-js-sdk/src/client.ts(1273,13): error TS2322: Type 'undefined' is not assignable to type 'string'.
+node_modules/matrix-js-sdk/src/client.ts(1278,13): error TS2322: Type 'undefined' is not assignable to type 'string'.
+node_modules/matrix-js-sdk/src/client.ts(1286,17): error TS2322: Type 'undefined' is not assignable to type 'string'.
+node_modules/matrix-js-sdk/src/client.ts(1300,17): error TS2345: Argument of type 'undefined' is not assignable to parameter of type 'Callback<{ success: boolean; }>'.
+node_modules/matrix-js-sdk/src/client.ts(1326,17): error TS2322: Type 'undefined' is not assignable to type 'string'.
+node_modules/matrix-js-sdk/src/client.ts(1341,17): error TS2345: Argument of type 'undefined' is not assignable to parameter of type 'Callback'.
+node_modules/matrix-js-sdk/src/client.ts(1350,60): error TS2571: Object is of type 'unknown'.
+node_modules/matrix-js-sdk/src/client.ts(1351,13): error TS2322: Type 'undefined' is not assignable to type 'IDehydratedDevice'.
+node_modules/matrix-js-sdk/src/client.ts(1373,13): error TS2322: Type 'undefined' is not assignable to type 'Promise'.
+node_modules/matrix-js-sdk/src/client.ts(1394,13): error TS2322: Type 'undefined' is not assignable to type 'string'.
+node_modules/matrix-js-sdk/src/client.ts(1403,13): error TS2322: Type 'undefined' is not assignable to type 'IExportedDevice'.
+node_modules/matrix-js-sdk/src/client.ts(1406,13): error TS2322: Type 'string | undefined' is not assignable to type 'string'.
+ Type 'undefined' is not assignable to type 'string'.
+node_modules/matrix-js-sdk/src/client.ts(1407,13): error TS2322: Type 'string | undefined' is not assignable to type 'string'.
+ Type 'undefined' is not assignable to type 'string'.
+node_modules/matrix-js-sdk/src/client.ts(1452,9): error TS2322: Type 'null' is not assignable to type 'string'.
+node_modules/matrix-js-sdk/src/client.ts(1471,9): error TS2322: Type 'string | undefined' is not assignable to type 'string'.
+ Type 'undefined' is not assignable to type 'string'.
+node_modules/matrix-js-sdk/src/client.ts(1525,13): error TS2322: Type 'null' is not assignable to type 'SyncState'.
+node_modules/matrix-js-sdk/src/client.ts(1635,13): error TS2345: Argument of type 'undefined' is not assignable to parameter of type 'Callback'.
+node_modules/matrix-js-sdk/src/client.ts(1639,17): error TS2345: Argument of type '(r?: { capabilities?: ICapabilities | undefined; }) => ICapabilities' is not assignable to parameter of type '(value: unknown) => ICapabilities | PromiseLike'.
+ Types of parameters 'r' and 'value' are incompatible.
+ Type 'unknown' is not assignable to type '{ capabilities?: ICapabilities | undefined; } | undefined'.
+node_modules/matrix-js-sdk/src/client.ts(1709,13): error TS2345: Argument of type 'string | undefined' is not assignable to parameter of type 'string'.
+ Type 'undefined' is not assignable to type 'string'.
+node_modules/matrix-js-sdk/src/client.ts(1734,16): error TS2790: The operand of a 'delete' operator must be optional.
+node_modules/matrix-js-sdk/src/client.ts(1758,27): error TS2322: Type 'null' is not assignable to type 'string'.
+node_modules/matrix-js-sdk/src/client.ts(1769,27): error TS2322: Type 'null' is not assignable to type 'string'.
+node_modules/matrix-js-sdk/src/client.ts(1848,77): error TS2345: Argument of type 'null' is not assignable to parameter of type 'boolean'.
+node_modules/matrix-js-sdk/src/client.ts(1874,61): error TS2345: Argument of type 'null' is not assignable to parameter of type 'boolean'.
+node_modules/matrix-js-sdk/src/client.ts(1892,61): error TS2345: Argument of type 'null' is not assignable to parameter of type 'boolean'.
+node_modules/matrix-js-sdk/src/client.ts(1966,56): error TS2345: Argument of type 'string[] | undefined' is not assignable to parameter of type 'string[]'.
+ Type 'undefined' is not assignable to type 'string[]'.
+node_modules/matrix-js-sdk/src/client.ts(2363,65): error TS2345: Argument of type 'string | undefined' is not assignable to parameter of type 'string'.
+ Type 'undefined' is not assignable to type 'string'.
+node_modules/matrix-js-sdk/src/client.ts(2379,48): error TS2345: Argument of type 'string | undefined' is not assignable to parameter of type 'string'.
+ Type 'undefined' is not assignable to type 'string'.
+node_modules/matrix-js-sdk/src/client.ts(2504,13): error TS2322: Type 'null' is not assignable to type 'DeviceInfo'.
+node_modules/matrix-js-sdk/src/client.ts(2506,9): error TS2322: Type 'DeviceInfo | null' is not assignable to type 'DeviceInfo'.
+ Type 'null' is not assignable to type 'DeviceInfo'.
+node_modules/matrix-js-sdk/src/client.ts(2533,61): error TS2345: Argument of type 'string | null' is not assignable to parameter of type 'string'.
+ Type 'null' is not assignable to type 'string'.
+node_modules/matrix-js-sdk/src/client.ts(2668,17): error TS2345: Argument of type 'undefined' is not assignable to parameter of type 'Callback'.
+node_modules/matrix-js-sdk/src/client.ts(2672,17): error TS2571: Object is of type 'unknown'.
+node_modules/matrix-js-sdk/src/client.ts(2705,9): error TS2322: Type 'boolean | null' is not assignable to type 'boolean'.
+ Type 'null' is not assignable to type 'boolean'.
+node_modules/matrix-js-sdk/src/client.ts(2824,13): error TS2345: Argument of type 'undefined' is not assignable to parameter of type 'Callback'.
+node_modules/matrix-js-sdk/src/client.ts(2856,13): error TS2345: Argument of type 'undefined' is not assignable to parameter of type 'Callback'.
+node_modules/matrix-js-sdk/src/client.ts(2872,17): error TS2322: Type 'string | undefined' is not assignable to type 'string'.
+ Type 'undefined' is not assignable to type 'string'.
+node_modules/matrix-js-sdk/src/client.ts(2895,12): error TS2394: This overload signature is not compatible with its implementation signature.
+node_modules/matrix-js-sdk/src/client.ts(2908,22): error TS2769: No overload matches this call.
+ Overload 1 of 3, '(roomId: undefined, sessionId: undefined, version: string): IKeyBackupPath', gave the following error.
+ Argument of type 'string' is not assignable to parameter of type 'undefined'.
+ Overload 2 of 3, '(roomId: string, sessionId: undefined, version: string): IKeyBackupPath', gave the following error.
+ Argument of type 'string | undefined' is not assignable to parameter of type 'undefined'.
+ Type 'string' is not assignable to type 'undefined'.
+ Overload 3 of 3, '(roomId: string, sessionId: string, version: string): IKeyBackupPath', gave the following error.
+ Argument of type 'string | undefined' is not assignable to parameter of type 'string'.
+ Type 'undefined' is not assignable to type 'string'.
+node_modules/matrix-js-sdk/src/client.ts(2910,13): error TS2345: Argument of type 'undefined' is not assignable to parameter of type 'Callback'.
+node_modules/matrix-js-sdk/src/client.ts(3019,22): error TS2769: No overload matches this call.
+ Overload 1 of 3, '(privKey: ArrayLike, targetRoomId: undefined, targetSessionId: undefined, backupInfo: IKeyBackupInfo, opts?: IKeyBackupRestoreOpts | undefined): Promise<...>', gave the following error.
+ Argument of type 'string | undefined' is not assignable to parameter of type 'undefined'.
+ Type 'string' is not assignable to type 'undefined'.
+ Overload 2 of 3, '(privKey: ArrayLike, targetRoomId: string, targetSessionId: undefined, backupInfo: IKeyBackupInfo, opts?: IKeyBackupRestoreOpts | undefined): Promise<...>', gave the following error.
+ Argument of type 'string | undefined' is not assignable to parameter of type 'string'.
+ Type 'undefined' is not assignable to type 'string'.
+ Overload 3 of 3, '(privKey: ArrayLike, targetRoomId: string, targetSessionId: string, backupInfo: IKeyBackupInfo, opts?: IKeyBackupRestoreOpts | undefined): Promise<...>', gave the following error.
+ Argument of type 'string | undefined' is not assignable to parameter of type 'string'.
+ Type 'undefined' is not assignable to type 'string'.
+node_modules/matrix-js-sdk/src/client.ts(3054,22): error TS2769: No overload matches this call.
+ Overload 1 of 3, '(privKey: ArrayLike, targetRoomId: undefined, targetSessionId: undefined, backupInfo: IKeyBackupInfo, opts?: IKeyBackupRestoreOpts | undefined): Promise<...>', gave the following error.
+ Argument of type 'string | undefined' is not assignable to parameter of type 'undefined'.
+ Type 'string' is not assignable to type 'undefined'.
+ Overload 2 of 3, '(privKey: ArrayLike, targetRoomId: string, targetSessionId: undefined, backupInfo: IKeyBackupInfo, opts?: IKeyBackupRestoreOpts | undefined): Promise<...>', gave the following error.
+ Argument of type 'string | undefined' is not assignable to parameter of type 'string'.
+ Type 'undefined' is not assignable to type 'string'.
+ Overload 3 of 3, '(privKey: ArrayLike, targetRoomId: string, targetSessionId: string, backupInfo: IKeyBackupInfo, opts?: IKeyBackupRestoreOpts | undefined): Promise<...>', gave the following error.
+ Argument of type 'string | undefined' is not assignable to parameter of type 'string'.
+ Type 'undefined' is not assignable to type 'string'.
+node_modules/matrix-js-sdk/src/client.ts(3101,47): error TS2769: No overload matches this call.
+ Overload 1 of 3, '(privKey: ArrayLike, targetRoomId: undefined, targetSessionId: undefined, backupInfo: IKeyBackupInfo, opts?: IKeyBackupRestoreOpts | undefined): Promise<...>', gave the following error.
+ Argument of type 'string | undefined' is not assignable to parameter of type 'undefined'.
+ Type 'string' is not assignable to type 'undefined'.
+ Overload 2 of 3, '(privKey: ArrayLike, targetRoomId: string, targetSessionId: undefined, backupInfo: IKeyBackupInfo, opts?: IKeyBackupRestoreOpts | undefined): Promise<...>', gave the following error.
+ Argument of type 'string | undefined' is not assignable to parameter of type 'string'.
+ Type 'undefined' is not assignable to type 'string'.
+ Overload 3 of 3, '(privKey: ArrayLike, targetRoomId: string, targetSessionId: string, backupInfo: IKeyBackupInfo, opts?: IKeyBackupRestoreOpts | undefined): Promise<...>', gave the following error.
+ Argument of type 'string | undefined' is not assignable to parameter of type 'string'.
+ Type 'undefined' is not assignable to type 'string'.
+node_modules/matrix-js-sdk/src/client.ts(3132,47): error TS2769: No overload matches this call.
+ Overload 1 of 3, '(privKey: ArrayLike, targetRoomId: undefined, targetSessionId: undefined, backupInfo: IKeyBackupInfo, opts?: IKeyBackupRestoreOpts | undefined): Promise<...>', gave the following error.
+ Argument of type 'string | undefined' is not assignable to parameter of type 'undefined'.
+ Type 'string' is not assignable to type 'undefined'.
+ Overload 2 of 3, '(privKey: ArrayLike, targetRoomId: string, targetSessionId: undefined, backupInfo: IKeyBackupInfo, opts?: IKeyBackupRestoreOpts | undefined): Promise<...>', gave the following error.
+ Argument of type 'string | undefined' is not assignable to parameter of type 'string'.
+ Type 'undefined' is not assignable to type 'string'.
+ Overload 3 of 3, '(privKey: ArrayLike, targetRoomId: string, targetSessionId: string, backupInfo: IKeyBackupInfo, opts?: IKeyBackupRestoreOpts | undefined): Promise<...>', gave the following error.
+ Argument of type 'string | undefined' is not assignable to parameter of type 'string'.
+ Type 'undefined' is not assignable to type 'string'.
+node_modules/matrix-js-sdk/src/client.ts(3173,45): error TS2769: No overload matches this call.
+ Overload 1 of 3, '(roomId: undefined, sessionId: undefined, version: string): IKeyBackupPath', gave the following error.
+ Argument of type 'string | undefined' is not assignable to parameter of type 'undefined'.
+ Type 'string' is not assignable to type 'undefined'.
+ Overload 2 of 3, '(roomId: string, sessionId: undefined, version: string): IKeyBackupPath', gave the following error.
+ Argument of type 'string | undefined' is not assignable to parameter of type 'string'.
+ Type 'undefined' is not assignable to type 'string'.
+ Overload 3 of 3, '(roomId: string, sessionId: string, version: string): IKeyBackupPath', gave the following error.
+ Argument of type 'string | undefined' is not assignable to parameter of type 'string'.
+ Type 'undefined' is not assignable to type 'string'.
+node_modules/matrix-js-sdk/src/client.ts(3201,17): error TS2345: Argument of type 'undefined' is not assignable to parameter of type 'Callback'.
+node_modules/matrix-js-sdk/src/client.ts(3222,21): error TS2322: Type 'string | undefined' is not assignable to type 'string'.
+ Type 'undefined' is not assignable to type 'string'.
+node_modules/matrix-js-sdk/src/client.ts(3228,25): error TS2464: A computed property name must be of type 'string', 'number', 'symbol', or 'any'.
+node_modules/matrix-js-sdk/src/client.ts(3230,21): error TS2322: Type 'string | undefined' is not assignable to type 'string'.
+ Type 'undefined' is not assignable to type 'string'.
+node_modules/matrix-js-sdk/src/client.ts(3231,21): error TS2322: Type 'string | undefined' is not assignable to type 'string'.
+ Type 'undefined' is not assignable to type 'string'.
+node_modules/matrix-js-sdk/src/client.ts(3264,45): error TS2769: No overload matches this call.
+ Overload 1 of 3, '(roomId: undefined, sessionId: undefined, version: string): IKeyBackupPath', gave the following error.
+ Argument of type 'string | undefined' is not assignable to parameter of type 'undefined'.
+ Type 'string' is not assignable to type 'undefined'.
+ Overload 2 of 3, '(roomId: string, sessionId: undefined, version: string): IKeyBackupPath', gave the following error.
+ Argument of type 'string | undefined' is not assignable to parameter of type 'string'.
+ Type 'undefined' is not assignable to type 'string'.
+ Overload 3 of 3, '(roomId: string, sessionId: string, version: string): IKeyBackupPath', gave the following error.
+ Argument of type 'string | undefined' is not assignable to parameter of type 'string'.
+ Type 'undefined' is not assignable to type 'string'.
+node_modules/matrix-js-sdk/src/client.ts(3266,13): error TS2345: Argument of type 'undefined' is not assignable to parameter of type 'Callback'.
+node_modules/matrix-js-sdk/src/client.ts(3293,13): error TS7053: Element implicitly has an 'any' type because expression of type 'string' can't be used to index type '{}'.
+ No index signature with a parameter of type 'string' was found on type '{}'.
+node_modules/matrix-js-sdk/src/client.ts(3312,13): error TS2345: Argument of type 'Callback | undefined' is not assignable to parameter of type 'Callback'.
+ Type 'undefined' is not assignable to type 'Callback'.
+node_modules/matrix-js-sdk/src/client.ts(3398,13): error TS2322: Type 'string | undefined' is not assignable to type 'string'.
+ Type 'undefined' is not assignable to type 'string'.
+node_modules/matrix-js-sdk/src/client.ts(3402,44): error TS2345: Argument of type 'undefined' is not assignable to parameter of type 'Callback'.
+node_modules/matrix-js-sdk/src/client.ts(3407,9): error TS2322: Type 'Promise' is not assignable to type 'Promise<{}>'.
+ Type 'unknown' is not assignable to type '{}'.
+node_modules/matrix-js-sdk/src/client.ts(3432,17): error TS2322: Type 'null' is not assignable to type 'T'.
+ 'T' could be instantiated with an arbitrary type which could be unrelated to 'null'.
+node_modules/matrix-js-sdk/src/client.ts(3439,13): error TS2322: Type 'string | undefined' is not assignable to type 'string'.
+ Type 'undefined' is not assignable to type 'string'.
+node_modules/matrix-js-sdk/src/client.ts(3443,50): error TS2345: Argument of type 'undefined' is not assignable to parameter of type 'Callback'.
+node_modules/matrix-js-sdk/src/client.ts(3445,17): error TS2571: Object is of type 'unknown'.
+node_modules/matrix-js-sdk/src/client.ts(3446,17): error TS2322: Type 'null' is not assignable to type 'T'.
+ 'T' could be instantiated with an arbitrary type which could be unrelated to 'null'.
+node_modules/matrix-js-sdk/src/client.ts(3472,13): error TS7053: Element implicitly has an 'any' type because expression of type 'string' can't be used to index type '{}'.
+ No index signature with a parameter of type 'string' was found on type '{}'.
+node_modules/matrix-js-sdk/src/client.ts(3510,45): error TS2345: Argument of type 'string | undefined' is not assignable to parameter of type 'string'.
+ Type 'undefined' is not assignable to type 'string'.
+node_modules/matrix-js-sdk/src/client.ts(3518,17): error TS2345: Argument of type 'undefined' is not assignable to parameter of type 'Callback'.
+node_modules/matrix-js-sdk/src/client.ts(3538,55): error TS2345: Argument of type 'undefined' is not assignable to parameter of type 'Callback'.
+node_modules/matrix-js-sdk/src/client.ts(3540,28): error TS2571: Object is of type 'unknown'.
+node_modules/matrix-js-sdk/src/client.ts(3592,35): error TS2345: Argument of type 'string | undefined' is not assignable to parameter of type 'string'.
+ Type 'undefined' is not assignable to type 'string'.
+node_modules/matrix-js-sdk/src/client.ts(3645,13): error TS2322: Type 'string | undefined' is not assignable to type 'string'.
+ Type 'undefined' is not assignable to type 'string'.
+node_modules/matrix-js-sdk/src/client.ts(3648,40): error TS2345: Argument of type 'Callback | undefined' is not assignable to parameter of type 'Callback'.
+ Type 'undefined' is not assignable to type 'Callback'.
+node_modules/matrix-js-sdk/src/client.ts(3661,13): error TS2322: Type 'string | undefined' is not assignable to type 'string'.
+ Type 'undefined' is not assignable to type 'string'.
+node_modules/matrix-js-sdk/src/client.ts(3665,40): error TS2345: Argument of type 'Callback | undefined' is not assignable to parameter of type 'Callback'.
+ Type 'undefined' is not assignable to type 'Callback'.
+node_modules/matrix-js-sdk/src/client.ts(3677,13): error TS2322: Type 'string | undefined' is not assignable to type 'string'.
+ Type 'undefined' is not assignable to type 'string'.
+node_modules/matrix-js-sdk/src/client.ts(3681,40): error TS2345: Argument of type 'Callback | undefined' is not assignable to parameter of type 'Callback'.
+ Type 'undefined' is not assignable to type 'Callback'.
+node_modules/matrix-js-sdk/src/client.ts(3699,13): error TS2322: Type 'string | undefined' is not assignable to type 'string'.
+ Type 'undefined' is not assignable to type 'string'.
+node_modules/matrix-js-sdk/src/client.ts(3703,40): error TS2345: Argument of type 'Callback | undefined' is not assignable to parameter of type 'Callback'.
+ Type 'undefined' is not assignable to type 'Callback'.
+node_modules/matrix-js-sdk/src/client.ts(3731,9): error TS7053: Element implicitly has an 'any' type because expression of type 'string' can't be used to index type '{}'.
+ No index signature with a parameter of type 'string' was found on type '{}'.
+node_modules/matrix-js-sdk/src/client.ts(3735,40): error TS2345: Argument of type 'Callback | undefined' is not assignable to parameter of type 'Callback'.
+ Type 'undefined' is not assignable to type 'Callback'.
+node_modules/matrix-js-sdk/src/client.ts(3765,83): error TS2345: Argument of type 'string | null' is not assignable to parameter of type 'string | undefined'.
+node_modules/matrix-js-sdk/src/client.ts(3778,12): error TS2394: This overload signature is not compatible with its implementation signature.
+node_modules/matrix-js-sdk/src/client.ts(3811,26): error TS7053: Element implicitly has an 'any' type because expression of type '"m.relates_to"' can't be used to index type 'string | IContent'.
+ Property 'm.relates_to' does not exist on type 'string | IContent'.
+node_modules/matrix-js-sdk/src/client.ts(3812,31): error TS7053: Element implicitly has an 'any' type because expression of type '"m.relates_to"' can't be used to index type 'string | IContent'.
+ Property 'm.relates_to' does not exist on type 'string | IContent'.
+node_modules/matrix-js-sdk/src/client.ts(3813,13): error TS7053: Element implicitly has an 'any' type because expression of type '"m.relates_to"' can't be used to index type 'string | IContent'.
+ Property 'm.relates_to' does not exist on type 'string | IContent'.
+node_modules/matrix-js-sdk/src/client.ts(3814,20): error TS7053: Element implicitly has an 'any' type because expression of type '"m.relates_to"' can't be used to index type 'string | IContent'.
+ Property 'm.relates_to' does not exist on type 'string | IContent'.
+node_modules/matrix-js-sdk/src/client.ts(3822,17): error TS7053: Element implicitly has an 'any' type because expression of type '"m.relates_to"' can't be used to index type 'string | IContent'.
+ Property 'm.relates_to' does not exist on type 'string | IContent'.
+node_modules/matrix-js-sdk/src/client.ts(3869,40): error TS2345: Argument of type 'string | null' is not assignable to parameter of type 'string'.
+ Type 'null' is not assignable to type 'string'.
+node_modules/matrix-js-sdk/src/client.ts(3889,28): error TS2531: Object is possibly 'null'.
+node_modules/matrix-js-sdk/src/client.ts(3890,13): error TS2532: Object is possibly 'undefined'.
+node_modules/matrix-js-sdk/src/client.ts(3891,47): error TS2532: Object is possibly 'undefined'.
+node_modules/matrix-js-sdk/src/client.ts(3911,41): error TS2345: Argument of type 'Room | null' is not assignable to parameter of type 'Room'.
+ Type 'null' is not assignable to type 'Room'.
+node_modules/matrix-js-sdk/src/client.ts(3949,17): error TS2322: Type 'Promise | null' is not assignable to type 'Promise'.
+ Type 'null' is not assignable to type 'Promise'.
+node_modules/matrix-js-sdk/src/client.ts(3950,21): error TS2801: This condition will always return true since this 'Promise' is always defined.
+node_modules/matrix-js-sdk/src/client.ts(3957,18): error TS2454: Variable 'promise' is used before being assigned.
+node_modules/matrix-js-sdk/src/client.ts(3985,61): error TS2571: Object is of type 'unknown'.
+node_modules/matrix-js-sdk/src/client.ts(4005,35): error TS2345: Argument of type 'string | undefined' is not assignable to parameter of type 'string'.
+ Type 'undefined' is not assignable to type 'string'.
+node_modules/matrix-js-sdk/src/client.ts(4037,48): error TS2345: Argument of type 'Room | undefined' is not assignable to parameter of type 'Room'.
+ Type 'undefined' is not assignable to type 'Room'.
+node_modules/matrix-js-sdk/src/client.ts(4078,40): error TS2532: Object is possibly 'undefined'.
+node_modules/matrix-js-sdk/src/client.ts(4081,50): error TS2345: Argument of type '{ $roomId: string | undefined; $eventType: string; $stateKey: string | undefined; $txnId: string; }' is not assignable to parameter of type 'Record'.
+ Property '$roomId' is incompatible with index signature.
+ Type 'string | undefined' is not assignable to type 'string'.
+ Type 'undefined' is not assignable to type 'string'.
+node_modules/matrix-js-sdk/src/client.ts(4084,50): error TS2345: Argument of type '{ $redactsEventId: string | undefined; } & { $roomId: string | undefined; $eventType: string; $stateKey: string | undefined; $txnId: string; }' is not assignable to parameter of type 'Record'.
+ Property '$redactsEventId' is incompatible with index signature.
+ Type 'string | undefined' is not assignable to type 'string'.
+ Type 'undefined' is not assignable to type 'string'.
+node_modules/matrix-js-sdk/src/client.ts(4088,77): error TS2345: Argument of type '{ $roomId: string | undefined; $eventType: string; $stateKey: string | undefined; $txnId: string; }' is not assignable to parameter of type 'Record'.
+node_modules/matrix-js-sdk/src/client.ts(4092,13): error TS2345: Argument of type 'undefined' is not assignable to parameter of type 'Callback'.
+node_modules/matrix-js-sdk/src/client.ts(4133,13): error TS2322: Type 'string | null' is not assignable to type 'string | undefined'.
+node_modules/matrix-js-sdk/src/client.ts(4155,12): error TS2394: This overload signature is not compatible with its implementation signature.
+node_modules/matrix-js-sdk/src/client.ts(4191,17): error TS2322: Type 'null' is not assignable to type 'IPartialEvent