src/main/php/routing/Route.php
private function normalizePath(): string
    {
        $path = $this->path;
        if (substr($path, -1) === '$') {
            $path = substr($path, 0, strlen($path) - 1);
        }

        if (substr($path, -1) === '?') {
            $path = substr($path, 0, strlen($path) - 1);
        }

        return $path;
    }
private function normalizePath(): string
    {
        $path = $this->path;
        if (substr($path, -1) === '$') {
            $path = substr($path, 0, strlen($path) - 1);
        }

        if (substr($path, -1) === '?') {
            $path = substr($path, 0, strlen($path) - 1);
        }

        return $path;
    }
private function normalizePath ( ) : string { $ path = $ this -> path ; if ( substr ( $ path , - 1 ) === '$' ) { $ path = substr ( $ path , 0 , strlen ( $ path ) - 1 ) ; } if ( substr ( $ path , - 1 ) === '?' ) { $ path = substr ( $ path , 0 , strlen ( $ path ) - 1 ) ; } return $ path ; }
normalizes path for better understanding

@return  string
normalizes path for better understanding