diff options
| author | Mike Greiling <[email protected]> | 2014-05-29 02:30:18 -0500 |
|---|---|---|
| committer | Chris Rebert <[email protected]> | 2014-06-07 18:09:53 -0700 |
| commit | 632313d631b51d96557bb6576c0b41e33cbfb009 (patch) | |
| tree | be03b4a79253c7058ff71bee9ca4b80cd58a6ddd | |
| parent | 0be41096888201831c151864c0ab05cf0b5ca734 (diff) | |
| download | bootstrap-632313d631b51d96557bb6576c0b41e33cbfb009.tar.xz bootstrap-632313d631b51d96557bb6576c0b41e33cbfb009.zip | |
no need to check for href attribute on the scrollable element
| -rw-r--r-- | js/scrollspy.js | 5 |
1 files changed, 1 insertions, 4 deletions
diff --git a/js/scrollspy.js b/js/scrollspy.js index de4f98707..db493d7ed 100644 --- a/js/scrollspy.js +++ b/js/scrollspy.js @@ -14,16 +14,13 @@ // ========================== function ScrollSpy(element, options) { - var href var process = $.proxy(this.process, this) this.$element = $(element).is('body') ? $(window) : $(element) this.$body = $('body') this.$scrollElement = this.$element.on('scroll.bs.scrollspy', process) this.options = $.extend({}, ScrollSpy.DEFAULTS, options) - this.selector = (this.options.target - || ((href = $(element).attr('href')) && href.replace(/.*(?=#[^\s]+$)/, '')) //strip for ie7 - || '') + ' .nav li > a' + this.selector = (this.options.target || '') + ' .nav li > a' this.offsets = [] this.targets = [] this.activeTarget = null |
