protected function normalizeStaticRoutes(array $routes)
    {
        foreach (\array_keys($routes) as $key) {
            // If any of the keys are  an HTTP method then we are running on a newer version of
            // Lumen and FastRoute which means we can leave the routes as they are.
            if ($this->stringIsHttpMethod($key)) {
                return $routes;
            }
        }

        $normalized = [];

        // To normalize the routes we'll take the inner array which contains the routes method as the
        // key and make that the parent element on the array. We'll then add all routes for a
        // particular HTTP method as children of it by keying them to their URI.
        foreach ($routes as $uri => $value) {
            foreach ($value as $method => $route) {
                $normalized[$method][$uri] = $route;
            }
        }

        return $normalized;
    }