original_string: public static function cleanPath($path)
      {
          $regex = '/(\/)\/+/';
          $path = str_replace(['\\', '/ /'], '/', $path);
          $path = preg_replace($regex,'$1',$path);
  
          return $path;
      }
code: public static function cleanPath($path)
      {
          $regex = '/(\/)\/+/';
          $path = str_replace(['\\', '/ /'], '/', $path);
          $path = preg_replace($regex,'$1',$path);
  
          return $path;
      }
code_tokens: public static function cleanPath ( $ path ) { $ regex = '/(\/)\/+/' ; $ path = str_replace ( [ '\\' , '/ /' ] , '/' , $ path ) ; $ path = preg_replace ( $ regex , '$1' , $ path ) ; return $ path ; }
docstring: Removes extra double slashes and fixes back-slashes
  
  @param string $path
  @return mixed|string
docstring_tokens: Removes extra double slashes and fixes back - slashes