protected function doUnlink(string $path): bool
    {
        if (self::$root->getName() === $path) {
            // delete root? very brave. :)
            self::$root = null;
            clearstatcache();
            return true;
        }

        $names = $this->splitPath($path);

        /** @var vfsStreamDirectory $content */
        $content = $this->getContent($names['dirname']);
        if (!$content->isWritable(vfsStream::getCurrentUser(), vfsStream::getCurrentGroup())) {
            return false;
        }

        clearstatcache();
        return $content->removeChild($names['basename']);
    }
protected function doUnlink(string $path): bool
    {
        if (self::$root->getName() === $path) {
            // delete root? very brave. :)
            self::$root = null;
            clearstatcache();
            return true;
        }

        $names = $this->splitPath($path);

        /** @var vfsStreamDirectory $content */
        $content = $this->getContent($names['dirname']);
        if (!$content->isWritable(vfsStream::getCurrentUser(), vfsStream::getCurrentGroup())) {
            return false;
        }

        clearstatcache();
        return $content->removeChild($names['basename']);
    }
protected function doUnlink ( string $ path ) : bool { if ( self :: $ root -> getName ( ) === $ path ) { // delete root? very brave. :) self :: $ root = null ; clearstatcache ( ) ; return true ; } $ names = $ this -> splitPath ( $ path ) ; /** @var vfsStreamDirectory $content */ $ content = $ this -> getContent ( $ names [ 'dirname' ] ) ; if ( ! $ content -> isWritable ( vfsStream :: getCurrentUser ( ) , vfsStream :: getCurrentGroup ( ) ) ) { return false ; } clearstatcache ( ) ; return $ content -> removeChild ( $ names [ 'basename' ] ) ; }
removes a path

@param   string  $path
@return  bool
removes a path