fix #2751 - Media not rendered when Converse runs in a browser extension

This commit is contained in:
Dele Olajide 2021-12-15 13:41:44 +00:00 committed by JC Brand
parent f25f110e0e
commit 4bb4f932cf
2 changed files with 5 additions and 1 deletions

View File

@ -1,5 +1,9 @@
# Changelog
## 9.0.1 (2021-??-??)
- #2751: Media not rendered when Converse runs in a browser extension
## 9.0.0 (2021-11-26)
- Compress new avatar images before uploading them

View File

@ -21,7 +21,7 @@ export function getURI (url) {
function checkFileTypes (types, url) {
const uri = getURI(url);
if (uri === null || !checkTLS(uri)) {
if (window.location.protocol !== 'chrome-extension:' && (uri === null || !checkTLS(uri))) {
return false;
}
const filename = uri.filename().toLowerCase();