From 7f63a6f3219e2e17d4eb3d6bb6033046c3ccc2f2 Mon Sep 17 00:00:00 2001 From: dcore94 Date: Wed, 14 Jun 2023 19:30:21 +0200 Subject: [PATCH] removed too hard constraint on mime type --- ccp/js/inputwidgetcontroller.js | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/ccp/js/inputwidgetcontroller.js b/ccp/js/inputwidgetcontroller.js index 1aedbc2..12c98e3 100644 --- a/ccp/js/inputwidgetcontroller.js +++ b/ccp/js/inputwidgetcontroller.js @@ -169,13 +169,13 @@ class FileInputRenderer extends Renderer{ const ename = tgt.getAttribute("name") if(ename === this.name){ const file = ev.target.files[0] - if(file.type !== this.schema.contentMediaType){ + /*if(file.type !== this.schema.contentMediaType){ alert("Unsupported media type. Must be " + this.schema.contentMediaType) ev.stopPropagation() ev.preventDefault() tgt.value = null return false - } + }*/ if(file.size > 100*1024){ alert("This input allows only small files (100K). Use references instead ") ev.stopPropagation()