public function staticPath()
{
$routeKey = strpos($this->template, ':');
if ($routeKey !== false) {
return substr($this->template, 0, $routeKey);
}
$star = strpos($this->template, '*');
if ($star !== false) {
$path = rtrim(substr($this->template, 0, $star), '/');
return $path === '' ? '/' : $path;
}
return $this->template;
}