Skip to content

Commit decc3b0

Browse files
committed
tidy: extdeps.rs: Avoid an unnecessary collect()
1 parent 896c3ce commit decc3b0

File tree

1 file changed

+1
-2
lines changed

1 file changed

+1
-2
lines changed

src/tools/tidy/src/extdeps.rs

Lines changed: 1 addition & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -37,8 +37,7 @@ pub fn check(path: &Path, bad: &mut bool) {
3737
}
3838

3939
// extract source value
40-
let parts: Vec<&str> = line.splitn(2, '=').collect();
41-
let source = parts[1].trim();
40+
let source = line.splitn(2, '=').nth(1).unwrap().trim();
4241

4342
// ensure source is whitelisted
4443
if !WHITELISTED_SOURCES.contains(&&*source) {

0 commit comments

Comments
 (0)