code: public static function getPath(string $file)
    {
      $parts = explode('/', $file);
      array_pop($parts);
      return implode('/', $parts);
    }
docs: Returns the file path
  
  @param  string  $file
  @return string