Conform more of the codebase to strictNullChecks (#10738)
This commit is contained in:
committed by
GitHub
parent
5e8488c283
commit
52017f62e1
@@ -197,8 +197,14 @@ class NotifierClass {
|
||||
|
||||
// Ideally in here we could use MSC1310 to detect the type of file, and reject it.
|
||||
|
||||
const url = mediaFromMxc(content.url).srcHttp;
|
||||
if (!url) {
|
||||
logger.warn("Something went wrong when generating src http url for mxc");
|
||||
return null;
|
||||
}
|
||||
|
||||
return {
|
||||
url: mediaFromMxc(content.url).srcHttp,
|
||||
url,
|
||||
name: content.name,
|
||||
type: content.type,
|
||||
size: content.size,
|
||||
|
||||
Reference in New Issue
Block a user