Skip to content

Commit 7ecdbfc

Browse files
author
Krishna Sundarram
committed
Replace one more usage of fs::remove_dir_all
1 parent 0162a95 commit 7ecdbfc

File tree

1 file changed

+3
-1
lines changed

1 file changed

+3
-1
lines changed

src/rustup-dist/src/temp.rs

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,3 +1,5 @@
1+
extern crate remove_dir_all;
2+
13
use std::error;
24
use std::fs;
35
use std::path::{Path, PathBuf};
@@ -237,7 +239,7 @@ impl<'a> ops::Deref for File<'a> {
237239
impl<'a> Drop for Dir<'a> {
238240
fn drop(&mut self) {
239241
if raw::is_directory(&self.path) {
240-
let n = Notification::DirectoryDeletion(&self.path, fs::remove_dir_all(&self.path));
242+
let n = Notification::DirectoryDeletion(&self.path, remove_dir_all::remove_dir_all(&self.path));
241243
(self.cfg.notify_handler)(n);
242244
}
243245
}

0 commit comments

Comments
 (0)