Conform more of the codebase to strict typescript (#10841)
This commit is contained in:
@@ -146,7 +146,7 @@ export class CallStore extends AsyncStoreWithClient<{}> {
|
||||
this.calls.set(room.roomId, call);
|
||||
this.callListeners.set(
|
||||
call,
|
||||
new Map<CallEvent, (...args: unknown[]) => unknown>([
|
||||
new Map<CallEvent, (...args: any[]) => unknown>([
|
||||
[CallEvent.ConnectionState, onConnectionState],
|
||||
[CallEvent.Destroy, onDestroy],
|
||||
]),
|
||||
|
||||
@@ -42,8 +42,12 @@ export class RoomScrollStateStore {
|
||||
return this.scrollStateMap.get(roomId);
|
||||
}
|
||||
|
||||
public setScrollState(roomId: string, scrollState: ScrollState): void {
|
||||
this.scrollStateMap.set(roomId, scrollState);
|
||||
public setScrollState(roomId: string, scrollState: ScrollState | null): void {
|
||||
if (scrollState === null) {
|
||||
this.scrollStateMap.delete(roomId);
|
||||
} else {
|
||||
this.scrollStateMap.set(roomId, scrollState);
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user