refactored CosmicDawn importer - now working!

Signed-off-by: Stephan Richter <s.richter@srsoftware.de>
This commit is contained in:
2025-01-01 20:01:40 +01:00
parent af4a06afc0
commit e0dde9aa9e
3 changed files with 78 additions and 35 deletions
@@ -8,7 +8,7 @@ function attachmentList(json){
var attachments = document.getElementById('attachments');
attachments.innerHTML = '';
for (var attachment of json){
if (attachment.mime.startsWith('image')){
if (attachment.mime.startsWith('image')||attachment.url.includes('.jpg')||attachment.url.includes('.png')||attachment.url.includes('.gif')){
var img = document.createElement('img');
img.src = attachment.url;
attachments.appendChild(img);