From 7018e03c83946695014ce8aa15fe9b6fbdddae32 Mon Sep 17 00:00:00 2001 From: Laurens Meurs Date: Thu, 2 Apr 2015 21:50:34 +0200 Subject: [PATCH] Issue #2301527 by lmeurs: Client side file extension validation for managed files fails on Internet Explorer 11 --- modules/file/file.js | 6 ++++++ 1 file changed, 6 insertions(+) diff --git a/modules/file/file.js b/modules/file/file.js index fffec6b..50f12b1 100644 --- a/modules/file/file.js +++ b/modules/file/file.js @@ -64,6 +64,12 @@ Drupal.file = Drupal.file || { * Client-side file input validation of file extensions. */ validateExtension: function (event) { + // On IE 11 setting value programatically will trigger a change event. + // Prevent any action when value is empty. + if (this.value === '') { + return; + } + // Remove any previous errors. $('.file-upload-js-error').remove(); -- 1.9.0.msysgit.0