src/Menu/Menu.php
protected function isActiveUrl(array $values)
    {
        // Do we have a custom resolver? If so, use it:
        if($activeUrlResolver = $this->activeUrlResolver) {
            return $activeUrlResolver($values);
        }

        // If the current URL is the base URL or the exact attribute is set to true, then check for the exact URL
        if ($values['exact'] ?? false || $values['url'] == $this->baseUrl) {
            return $this->activeUrl === $values['url'];
        }

        // Otherwise use the default resolver:
        return strpos($this->activeUrl, $values['url']) === 0;
    }
protected function isActiveUrl(array $values)
    {
        // Do we have a custom resolver? If so, use it:
        if($activeUrlResolver = $this->activeUrlResolver) {
            return $activeUrlResolver($values);
        }

        // If the current URL is the base URL or the exact attribute is set to true, then check for the exact URL
        if ($values['exact'] ?? false || $values['url'] == $this->baseUrl) {
            return $this->activeUrl === $values['url'];
        }

        // Otherwise use the default resolver:
        return strpos($this->activeUrl, $values['url']) === 0;
    }
protected function isActiveUrl ( array $ values ) { // Do we have a custom resolver? If so, use it: if ( $ activeUrlResolver = $ this -> activeUrlResolver ) { return $ activeUrlResolver ( $ values ) ; } // If the current URL is the base URL or the exact attribute is set to true, then check for the exact URL if ( $ values [ 'exact' ] ?? false || $ values [ 'url' ] == $ this -> baseUrl ) { return $ this -> activeUrl === $ values [ 'url' ] ; } // Otherwise use the default resolver: return strpos ( $ this -> activeUrl , $ values [ 'url' ] ) === 0 ; }
Checks whether this is the current URL or not

@param array $values
@return bool
Checks whether this is the current URL or not