Conform more code to strict null checking (#10167)
* Conform more code to strict null checking * Delint * Iterate PR based on feedback
This commit is contained in:
@@ -216,8 +216,8 @@ export class StopGapWidget extends EventEmitter {
|
||||
const defaults: ITemplateParams = {
|
||||
widgetRoomId: this.roomId,
|
||||
currentUserId: this.client.getUserId()!,
|
||||
userDisplayName: OwnProfileStore.instance.displayName,
|
||||
userHttpAvatarUrl: OwnProfileStore.instance.getHttpAvatarUrl(),
|
||||
userDisplayName: OwnProfileStore.instance.displayName ?? undefined,
|
||||
userHttpAvatarUrl: OwnProfileStore.instance.getHttpAvatarUrl() ?? undefined,
|
||||
clientId: ELEMENT_CLIENT_ID,
|
||||
clientTheme: SettingsStore.getValue("theme"),
|
||||
clientLanguage: getUserLanguage(),
|
||||
|
||||
@@ -477,7 +477,7 @@ export class WidgetLayoutStore extends ReadyWatchingStore {
|
||||
this.updateUserLayout(room, newLayout);
|
||||
}
|
||||
|
||||
public hasMaximisedWidget(room: Room): boolean {
|
||||
public hasMaximisedWidget(room?: Room): boolean {
|
||||
return this.getContainerWidgets(room, Container.Center).length > 0;
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user