protected function getRoutes($method = null, array $routes = [])
    {
        if (null !== $method) {
            if (false === isset($routes[$method])) {
                throw new Doozr_Route_Exception(
                    sprintf(
                        'No routes for HTTP-method "%s" found.',
                        $method
                    ),
                    Doozr_Http::METHOD_NOT_ALLOWED
                );
            }
            $routes = $routes[$method];
        }

        return $routes;
    }
protected function getRoutes($method = null, array $routes = [])
    {
        if (null !== $method) {
            if (false === isset($routes[$method])) {
                throw new Doozr_Route_Exception(
                    sprintf(
                        'No routes for HTTP-method "%s" found.',
                        $method
                    ),
                    Doozr_Http::METHOD_NOT_ALLOWED
                );
            }
            $routes = $routes[$method];
        }

        return $routes;
    }
protected function getRoutes ( $ method = null , array $ routes = [ ] ) { if ( null !== $ method ) { if ( false === isset ( $ routes [ $ method ] ) ) { throw new Doozr_Route_Exception ( sprintf ( 'No routes for HTTP-method "%s" found.' , $ method ) , Doozr_Http :: METHOD_NOT_ALLOWED ) ; } $ routes = $ routes [ $ method ] ; } return $ routes ; }
Getter for routes.

@param string $method Optional method argument to return only routes for a specific method/verb.
@param array  $routes Routes to use for lookup

@author Benjamin Carl <opensource@clickalicious.de>

@return array Collection of stored routes

@throws Doozr_Route_Exception
Getter for routes .