public override bool RemoveDirectory(string path, StreamRemoveDirectoryOptions options, StreamContext context)
{
try
{
// Deletes the directory (but not the contents - must be empty)
Directory.Delete(path, false);
return true;
}
catch (UnauthorizedAccessException)
{
PhpException.Throw(PhpError.Warning, ErrResources.stream_file_access_denied, FileSystemUtils.StripPassword(path));
}
catch (IOException)
{
// Directory not empty.
PhpException.Throw(PhpError.Warning, ErrResources.stream_rmdir_io_error, FileSystemUtils.StripPassword(path));
}
return false;
}