diff options
author | Richard Dushime <45734838+richarddushime@users.noreply.github.com> | 2024-03-19 19:05:56 +0300 |
---|---|---|
committer | GitHub <noreply@github.com> | 2024-03-19 16:05:56 +0000 |
commit | 01ca220f83f549d03da566f4becdf826819747ae (patch) | |
tree | 43e7fb2dda3e536ce7e0d0427739a2fd70b78deb /components/script/dom/userscripts.rs | |
parent | 676f655647fe261c9a9f005122cbbca0263a2625 (diff) | |
download | servo-01ca220f83f549d03da566f4becdf826819747ae.tar.gz servo-01ca220f83f549d03da566f4becdf826819747ae.zip |
clippy: Fix many warnings in `components/script` (#31717)
* Fix Several clippy warnings
* Fix Build errors
* Fix Unused import
* Fix requested changes
* Fix rustfmt
* Minor fixes
---------
Co-authored-by: Martin Robinson <mrobinson@igalia.com>
Diffstat (limited to 'components/script/dom/userscripts.rs')
-rw-r--r-- | components/script/dom/userscripts.rs | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/components/script/dom/userscripts.rs b/components/script/dom/userscripts.rs index 2b64c606b06..10197dbcfb7 100644 --- a/components/script/dom/userscripts.rs +++ b/components/script/dom/userscripts.rs @@ -31,7 +31,7 @@ pub fn load_script(head: &HTMLHeadElement) { rooted!(in(*cx) let mut rval = UndefinedValue()); let path = PathBuf::from(&path_str); - let mut files = read_dir(&path) + let mut files = read_dir(path) .expect("Bad path passed to --userscripts") .filter_map(|e| e.ok()) .map(|e| e.path()) @@ -52,7 +52,7 @@ pub fn load_script(head: &HTMLHeadElement) { &file.to_string_lossy(), rval.handle_mut(), 1, - ScriptFetchOptions::default_classic_script(&global), + ScriptFetchOptions::default_classic_script(global), global.api_base_url(), ); } |