diff options
| author | nsfisis <nsfisis@gmail.com> | 2026-06-27 03:52:05 +0900 |
|---|---|---|
| committer | nsfisis <nsfisis@gmail.com> | 2026-06-27 04:21:34 +0900 |
| commit | 2b51554ff59d1e5cbf8dd2db65d278b0202a9102 (patch) | |
| tree | f4d9b0abf4df9b5e363e3bd65511d70e3d5ada00 /crates/shirabe/src/util/filesystem.rs | |
| parent | cc07b5abb83a40d678401c335bdc49bb81b72c5f (diff) | |
| download | php-shirabe-2b51554ff59d1e5cbf8dd2db65d278b0202a9102.tar.gz php-shirabe-2b51554ff59d1e5cbf8dd2db65d278b0202a9102.tar.zst php-shirabe-2b51554ff59d1e5cbf8dd2db65d278b0202a9102.zip | |
refactor: fix compiler warnings and clippy warnings
Diffstat (limited to 'crates/shirabe/src/util/filesystem.rs')
| -rw-r--r-- | crates/shirabe/src/util/filesystem.rs | 19 |
1 files changed, 9 insertions, 10 deletions
diff --git a/crates/shirabe/src/util/filesystem.rs b/crates/shirabe/src/util/filesystem.rs index ec1e65a..6dd2ab9 100644 --- a/crates/shirabe/src/util/filesystem.rs +++ b/crates/shirabe/src/util/filesystem.rs @@ -4,14 +4,13 @@ use shirabe_external_packages::composer::pcre::Preg; use shirabe_external_packages::symfony::filesystem::exception::IOException; use shirabe_external_packages::symfony::finder::Finder; use shirabe_php_shim::{ - DIRECTORY_SEPARATOR, ErrorException, InvalidArgumentException, LogicException, PhpMixed, - RuntimeException, UnexpectedValueException, array_pop, basename, chdir, clearstatcache, - clearstatcache2, copy, count, dirname, error_get_last, explode, fclose, feof, file_exists, - file_get_contents, file_put_contents, fileatime, filemtime, filesize, fopen, fread, - function_exists, fwrite, implode, is_array, is_dir, is_file, is_link, is_readable, lstat, - mkdir, react_promise_resolve, rename, rmdir, rtrim, sprintf, str_contains, str_repeat, - str_replace, str_starts_with, strlen, strpos, strtolower, strtoupper, strtr, substr, - substr_count, symlink, touch, unlink, usleep, var_export, + DIRECTORY_SEPARATOR, ErrorException, LogicException, PhpMixed, RuntimeException, array_pop, + basename, chdir, clearstatcache, clearstatcache2, copy, dirname, error_get_last, explode, + fclose, feof, file_exists, file_get_contents, file_put_contents, fileatime, filemtime, + filesize, fopen, fread, function_exists, fwrite, implode, is_dir, is_file, is_link, + is_readable, lstat, mkdir, rename, rmdir, rtrim, str_contains, str_repeat, str_replace, + str_starts_with, strlen, strpos, strtoupper, strtr, substr, substr_count, symlink, touch, + unlink, usleep, var_export, }; use std::path::Path; @@ -246,9 +245,9 @@ impl Filesystem { for file in &ri { if file.is_dir() { - self.rmdir(&file.get_pathname())?; + self.rmdir(file.get_pathname())?; } else { - self.unlink(&file.get_pathname())?; + self.unlink(file.get_pathname())?; } } |
