diff options
Diffstat (limited to 'modules/overlay')
-rw-r--r-- | modules/overlay/overlay-parent.js | 4 |
1 files changed, 3 insertions, 1 deletions
diff --git a/modules/overlay/overlay-parent.js b/modules/overlay/overlay-parent.js index 859091133..bb3067857 100644 --- a/modules/overlay/overlay-parent.js +++ b/modules/overlay/overlay-parent.js @@ -735,7 +735,9 @@ Drupal.overlay.resetActiveClass = function(activePath) { var linkDomain = this.protocol + this.hostname; var linkPath = self.getPath(this); - if (linkDomain == windowDomain && activePath.indexOf(linkPath) === 0) { + // A link matches if it is part of the active trail of activePath, except + // for frontpage links. + if (linkDomain == windowDomain && (activePath + '/').indexOf(linkPath + '/') === 0 && (linkPath !== '' || activePath === '')) { $(this).addClass('active'); } }); |