protected function normalize($path, $returnString = false)
    {
        // Clean the Directory separator
        $path = $this->clean($path);

        // Extract to array
        $path = $this->extract($path);

        // Remove dots from path
        $path = $this->removeDots($path);

        // If set to return string, compact it.
        if ($returnString == true) {
            $path = $this->compact($path);
        }

        return $path;
    }
protected function normalize($path, $returnString = false)
    {
        // Clean the Directory separator
        $path = $this->clean($path);

        // Extract to array
        $path = $this->extract($path);

        // Remove dots from path
        $path = $this->removeDots($path);

        // If set to return string, compact it.
        if ($returnString == true) {
            $path = $this->compact($path);
        }

        return $path;
    }
protected function normalize ( $ path , $ returnString = false ) { // Clean the Directory separator $ path = $ this -> clean ( $ path ) ; // Extract to array $ path = $ this -> extract ( $ path ) ; // Remove dots from path $ path = $ this -> removeDots ( $ path ) ; // If set to return string, compact it. if ( $ returnString == true ) { $ path = $ this -> compact ( $ path ) ; } return $ path ; }
Normalize path, remove not necessary elements.

@param  string $path         A given path to normalize.
@param  bool   $returnString Return string or array.

@return  string|array  Normalized path.

@since  2.0
Normalize path remove not necessary elements .