aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--js/popover.js1
-rw-r--r--js/tooltip.js1
2 files changed, 2 insertions, 0 deletions
diff --git a/js/popover.js b/js/popover.js
index df1a43d8d..84713bcc6 100644
--- a/js/popover.js
+++ b/js/popover.js
@@ -85,6 +85,7 @@
return this.each(function () {
var $this = $(this)
var data = $this.data('bs.popover')
+ if (!data && option === 'destroy') return
var options = typeof option == 'object' && option
if (!data) $this.data('bs.popover', (data = new Popover(this, options)))
diff --git a/js/tooltip.js b/js/tooltip.js
index b465b9a8e..0d3086e9a 100644
--- a/js/tooltip.js
+++ b/js/tooltip.js
@@ -376,6 +376,7 @@
return this.each(function () {
var $this = $(this)
var data = $this.data('bs.tooltip')
+ if (!data && option === 'destroy') return
var options = typeof option == 'object' && option
if (!data) $this.data('bs.tooltip', (data = new Tooltip(this, options)))