private function getMethods()
    {
        // Laravel <5.4
        if (method_exists($this->route, 'getMethods')) {
            return $this->route->getMethods();
        }
        // Laravel 5.4+
        return $this->route->methods();
    }