Explorar o código

fix bug with determing the width. fixes #242

Igor Vaynberg %!s(int64=13) %!d(string=hai) anos
pai
achega
0d5be21e09
Modificáronse 1 ficheiros con 2 adicións e 0 borrados
  1. 2 0
      select2.js

+ 2 - 0
select2.js

@@ -1138,6 +1138,8 @@
                         // finally, fallback on the calculated width of the element
                         return (this.opts.element.outerWidth() === 0 ? 'auto' : this.opts.element.outerWidth() + 'px');
                     }
+
+                    return null;
                 } else {
                     return this.opts.width;
                }