Conform more code to strictNullChecks
(#10383
* Update matrix-widget-api * Conform more code to `strictNullChecks` * Iterate
This commit is contained in:
parent
aae9dfbb7d
commit
9c816bb720
18 changed files with 112 additions and 93 deletions
|
@ -103,11 +103,11 @@ export const usePublicRoomDirectory = (): {
|
|||
if (query || roomTypes) {
|
||||
opts.filter = {
|
||||
generic_search_term: query,
|
||||
room_types: (await MatrixClientPeg.get().doesServerSupportUnstableFeature(
|
||||
"org.matrix.msc3827.stable",
|
||||
))
|
||||
? Array.from<RoomType | null>(roomTypes)
|
||||
: undefined,
|
||||
room_types:
|
||||
roomTypes &&
|
||||
(await MatrixClientPeg.get().doesServerSupportUnstableFeature("org.matrix.msc3827.stable"))
|
||||
? Array.from<RoomType | null>(roomTypes)
|
||||
: undefined,
|
||||
};
|
||||
}
|
||||
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue