core/server/helpers/navigation.js
function _isCurrentUrl(href, currentUrl) {
        if (!currentUrl) {
            return false;
        }

        var strippedHref = href.replace(/\/+$/, ''),
            strippedCurrentUrl = currentUrl.replace(/\/+$/, '');
        return strippedHref === strippedCurrentUrl;
    }
function _isCurrentUrl(href, currentUrl) {
        if (!currentUrl) {
            return false;
        }

        var strippedHref = href.replace(/\/+$/, ''),
            strippedCurrentUrl = currentUrl.replace(/\/+$/, '');
        return strippedHref === strippedCurrentUrl;
    }
function _isCurrentUrl ( href , currentUrl ) { if ( ! currentUrl ) { return false ; } var strippedHref = href . replace ( / \/+$ / , '' ) , strippedCurrentUrl = currentUrl . replace ( / \/+$ / , '' ) ; return strippedHref === strippedCurrentUrl ; }
strips trailing slashes and compares urls
strips trailing slashes and compares urls