src/Http/Cookie/Cookie.php
public function matchesPath($path)
    {
        if ($this->_data['path'] === '/' || $this->_data['path'] === $path) {
            return true;
        }

        if (strpos($path, $this->_data['path']) !== 0) {
            return false;
        }

        if (substr($this->_data['path'], -1, 1) === '/') {
            return true;
        }

        return substr($path, strlen($this->_data['path']), 1) === '/';
    }
public function matchesPath($path)
    {
        if ($this->_data['path'] === '/' || $this->_data['path'] === $path) {
            return true;
        }

        if (strpos($path, $this->_data['path']) !== 0) {
            return false;
        }

        if (substr($this->_data['path'], -1, 1) === '/') {
            return true;
        }

        return substr($path, strlen($this->_data['path']), 1) === '/';
    }
public function matchesPath ( $ path ) { if ( $ this -> _data [ 'path' ] === '/' || $ this -> _data [ 'path' ] === $ path ) { return true ; } if ( strpos ( $ path , $ this -> _data [ 'path' ] ) !== 0 ) { return false ; } if ( substr ( $ this -> _data [ 'path' ] , - 1 , 1 ) === '/' ) { return true ; } return substr ( $ path , strlen ( $ this -> _data [ 'path' ] ) , 1 ) === '/' ; }
Checks if a path match the Cookie path.

@param  string  $scheme The scheme name.
@return boolean         Returns `true` if schemes match, `false otherwise`.
Checks if a path match the Cookie path .