rustbuild: fix version parsing for browser-ui-test
This commit is contained in:
parent
2ead65f002
commit
d3f2d0cae0
1 changed files with 4 additions and 1 deletions
|
|
@ -905,7 +905,10 @@ fn get_browser_ui_test_version_inner(npm: &Path, global: bool) -> Option<String>
|
|||
.output()
|
||||
.map(|output| String::from_utf8_lossy(&output.stdout).into_owned())
|
||||
.unwrap_or(String::new());
|
||||
lines.lines().find_map(|l| l.split(":browser-ui-test@").skip(1).next()).map(|v| v.to_owned())
|
||||
lines
|
||||
.lines()
|
||||
.find_map(|l| l.split(':').nth(1)?.strip_prefix("browser-ui-test@"))
|
||||
.map(|v| v.to_owned())
|
||||
}
|
||||
|
||||
fn get_browser_ui_test_version(npm: &Path) -> Option<String> {
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue