aboutsummaryrefslogtreecommitdiff
path: root/js/bootstrap-collapse.js
diff options
context:
space:
mode:
authorfat <[email protected]>2012-12-22 13:48:16 -0800
committerfat <[email protected]>2012-12-22 13:48:16 -0800
commita9e661a2b5cc96e2148d62fa5ccd41522197ceef (patch)
tree122ec4dd53f16a85484f5f6277d9139db3877fd1 /js/bootstrap-collapse.js
parentfad0fb683bdcc71f5ffc9c18300dd19427b588ae (diff)
downloadbootstrap-a9e661a2b5cc96e2148d62fa5ccd41522197ceef.tar.xz
bootstrap-a9e661a2b5cc96e2148d62fa5ccd41522197ceef.zip
read data options in constructor for collapse
Diffstat (limited to 'js/bootstrap-collapse.js')
-rw-r--r--js/bootstrap-collapse.js2
1 files changed, 1 insertions, 1 deletions
diff --git a/js/bootstrap-collapse.js b/js/bootstrap-collapse.js
index 6755aa7e2..3498cdecb 100644
--- a/js/bootstrap-collapse.js
+++ b/js/bootstrap-collapse.js
@@ -129,7 +129,7 @@
return this.each(function () {
var $this = $(this)
, data = $this.data('collapse')
- , options = typeof option == 'object' && option
+ , options = $.extend({}, $.fn.collapse.defaults, $this.data(), typeof option == 'object' && option)
if (!data) $this.data('collapse', (data = new Collapse(this, options)))
if (typeof option == 'string') data[option]()
})