lib/url-pattern/url-match-pattern.js
function (protocol) {
        var matchRegexObject = this._matchPatternObject;

        return _.includes(ALLOWED_PROTOCOLS, protocol) &&
            (_.includes(matchRegexObject.protocols, MATCH_ALL) || _.includes(matchRegexObject.protocols, protocol));
    }
function (protocol) {
        var matchRegexObject = this._matchPatternObject;

        return _.includes(ALLOWED_PROTOCOLS, protocol) &&
            (_.includes(matchRegexObject.protocols, MATCH_ALL) || _.includes(matchRegexObject.protocols, protocol));
    }
function ( protocol ) { var matchRegexObject = this . _matchPatternObject ; return _ . includes ( ALLOWED_PROTOCOLS , protocol ) && ( _ . includes ( matchRegexObject . protocols , MATCH_ALL ) || _ . includes ( matchRegexObject . protocols , protocol ) ) ; }
Tests if the given protocol string, is allowed by the pattern.

@param {String=} protocol The protocol to be checked if the pattern allows.
@return {Boolean=}
Tests if the given protocol string is allowed by the pattern .