diff options
| author | XhmikosR <[email protected]> | 2017-07-27 13:39:55 +0300 |
|---|---|---|
| committer | XhmikosR <[email protected]> | 2017-08-23 00:05:38 +0300 |
| commit | ef8c77d8dcebd13559a141e419d003c2d10cc5f3 (patch) | |
| tree | fa0efba9d60de5570eeac2b7ae0262916d64401d /js/src/dropdown.js | |
| parent | 0492c3a4cd0aed19f46c5472a54ee8700c1a328e (diff) | |
| download | bootstrap-ef8c77d8dcebd13559a141e419d003c2d10cc5f3.tar.xz bootstrap-ef8c77d8dcebd13559a141e419d003c2d10cc5f3.zip | |
Tweak ESLint rules.
Diffstat (limited to 'js/src/dropdown.js')
| -rw-r--r-- | js/src/dropdown.js | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/js/src/dropdown.js b/js/src/dropdown.js index 5e792a527..e1c48ac6e 100644 --- a/js/src/dropdown.js +++ b/js/src/dropdown.js @@ -204,7 +204,7 @@ const Dropdown = (($) => { _getConfig(config) { const elementData = $(this._element).data() - if (elementData.placement !== undefined) { + if (typeof elementData.placement !== 'undefined') { elementData.placement = AttachmentMap[elementData.placement.toUpperCase()] } @@ -287,7 +287,7 @@ const Dropdown = (($) => { } if (typeof config === 'string') { - if (data[config] === undefined) { + if (typeof data[config] === 'undefined') { throw new Error(`No method named "${config}"`) } data[config]() |
