Browse Source

Update to release v5.0.7 fixes #1496

Kartik Visweswaran 5 years ago
parent
commit
4a656ecf33
3 changed files with 5 additions and 4 deletions
  1. 3 1
      CHANGE.md
  2. 2 3
      js/fileinput.js
  3. 0 0
      js/fileinput.min.js

+ 3 - 1
CHANGE.md

@@ -3,8 +3,10 @@ Change Log: `bootstrap-fileinput`
 
 ## version 5.0.7
 
-**Date:** _under development_
+**Date:** 17-Nov-2019
 
+- (enh #1496): Correct isEmpty check for functions.
+- (enh #1485): Update Portugese Brazilian Translations.
 - (enh #1479): Methods updated:
    - Include `addToStack` method.
    - Remove `updateStack` method

+ 2 - 3
js/fileinput.js

@@ -211,12 +211,11 @@
                 $modal.appendTo($body);
             }
         },
-        // https://stackoverflow.com/a/6000016
         isFunction: function (v) {
-            return !!(v && v.constructor && v.call && v.apply);
+            return typeof v === 'function';
         },
         isEmpty: function (value, trim) {
-            return value === undefined || value === null || (!$h.isFunction(value) && ( value.length === 0 || (trim && $.trim(value) === '')));
+            return value === undefined || value === null || (!$h.isFunction(value) && (value.length === 0 || (trim && $.trim(value) === '')));
         },
         isArray: function (a) {
             return Array.isArray(a) || Object.prototype.toString.call(a) === '[object Array]';

File diff suppressed because it is too large
+ 0 - 0
js/fileinput.min.js


Some files were not shown because too many files changed in this diff