Skip to content

Commit eadb12d

Browse files
committed
fix cargo clippy
1 parent b39b9fa commit eadb12d

File tree

3 files changed

+3
-3
lines changed

3 files changed

+3
-3
lines changed

crates/rspack_ids/src/id_helpers.rs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -68,7 +68,7 @@ pub fn get_short_module_name(module: &BoxModule, context: &str) -> String {
6868
};
6969
let name_for_condition = module.name_for_condition();
7070
if let Some(name_for_condition) = name_for_condition {
71-
return avoid_number(&make_paths_relative(context, &name_for_condition)).to_string();
71+
return avoid_number(&make_paths_relative(context, name_for_condition)).to_string();
7272
};
7373
"".to_string()
7474
}

crates/rspack_plugin_split_chunks/src/plugin/max_size.rs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -247,7 +247,7 @@ fn get_key(module: &dyn Module, delimiter: &str, compilation: &Compilation) -> S
247247
let name = if let Some(name_for_condition) = module.name_for_condition() {
248248
Cow::Owned(make_paths_relative(
249249
compilation.options.context.as_str(),
250-
&name_for_condition,
250+
name_for_condition,
251251
))
252252
} else {
253253
static RE: LazyLock<Regex> =

crates/rspack_plugin_split_chunks/src/plugin/module_group.rs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -334,7 +334,7 @@ impl SplitChunksPlugin {
334334
CacheGroupTest::String(str) => module
335335
.name_for_condition().is_some_and(|name| name.starts_with(str)),
336336
CacheGroupTest::RegExp(regexp) => module
337-
.name_for_condition().is_some_and(|name| regexp.test(&name)),
337+
.name_for_condition().is_some_and(|name| regexp.test(name)),
338338
CacheGroupTest::Fn(f) => {
339339
let ctx = CacheGroupTestFnCtx { compilation, module };
340340
f(ctx).await?.unwrap_or_default()

0 commit comments

Comments
 (0)