Commit 7cf7e42c authored by Chris Rebert's avatar Chris Rebert
Browse files

Merge branch 'hnrch02-modal-toggle'

parents fa4379de 4e4e4563
Showing with 2 additions and 2 deletions
+2 -2
...@@ -817,7 +817,7 @@ if (typeof jQuery === 'undefined') { throw new Error('Bootstrap\'s JavaScript re ...@@ -817,7 +817,7 @@ if (typeof jQuery === 'undefined') { throw new Error('Bootstrap\'s JavaScript re
} }
Modal.prototype.toggle = function (_relatedTarget) { Modal.prototype.toggle = function (_relatedTarget) {
return this[!this.isShown ? 'show' : 'hide'](_relatedTarget) return this.isShown ? this.hide() : this.show(_relatedTarget)
} }
Modal.prototype.show = function (_relatedTarget) { Modal.prototype.show = function (_relatedTarget) {
......
...@@ -36,7 +36,7 @@ ...@@ -36,7 +36,7 @@
} }
Modal.prototype.toggle = function (_relatedTarget) { Modal.prototype.toggle = function (_relatedTarget) {
return this[!this.isShown ? 'show' : 'hide'](_relatedTarget) return this.isShown ? this.hide() : this.show(_relatedTarget)
} }
Modal.prototype.show = function (_relatedTarget) { Modal.prototype.show = function (_relatedTarget) {
......
Supports Markdown
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment