Conform src/components/views/messages/*
code to strictNullChecks
(#10461)
This commit is contained in:
parent
7cb90d0f78
commit
cefd94859c
21 changed files with 109 additions and 96 deletions
|
@ -78,7 +78,7 @@ cacheDownloadIcon();
|
|||
* @param {HTMLElement} element The element to get the current style of.
|
||||
* @return {string} The CSS style encoded as a string.
|
||||
*/
|
||||
export function computedStyle(element: HTMLElement): string {
|
||||
export function computedStyle(element: HTMLElement | null): string {
|
||||
if (!element) {
|
||||
return "";
|
||||
}
|
||||
|
@ -142,6 +142,7 @@ export default class MFileBody extends React.Component<IProps, IState> {
|
|||
}
|
||||
|
||||
private downloadFile(fileName: string, text: string): void {
|
||||
if (!this.state.decryptedBlob) return;
|
||||
this.fileDownloader.download({
|
||||
blob: this.state.decryptedBlob,
|
||||
name: fileName,
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue