Apply strictNullChecks to src/utils/*!exportUtils (#10455
* Apply `strictNullChecks` to `src/utils/exportUtils` * strict fix * fix strictNullChecks issues in some utils * fix error message * test coverage * lint * more strictNullChecks * small optimisation for getUniqueRoomsWithIndividuals * tidy * test coverage
This commit is contained in:
@@ -102,7 +102,10 @@ export class MediaEventHelper implements IDestroyable {
|
||||
}
|
||||
}
|
||||
|
||||
return fetch(this.media.thumbnailHttp).then((r) => r.blob());
|
||||
const thumbnailHttp = this.media.thumbnailHttp;
|
||||
if (!thumbnailHttp) return Promise.resolve(null);
|
||||
|
||||
return fetch(thumbnailHttp).then((r) => r.blob());
|
||||
};
|
||||
|
||||
public static isEligible(event: MatrixEvent): boolean {
|
||||
|
||||
Reference in New Issue
Block a user