1
0
mirror of https://github.com/jht5945/buildj.git synced 2026-01-12 08:20:03 +08:00

chore: code style

This commit is contained in:
2020-09-20 17:36:27 +08:00
parent e227603ab2
commit 6fa4b60bc4
7 changed files with 56 additions and 95 deletions

View File

@@ -106,17 +106,17 @@ pub fn find_build_json_in_parents() -> Option<String> {
}
pub fn find_build_json() -> Option<String> {
match find_build_json_in_current() {
Some(p) => Some(p),
None => match find_build_json_in_parents() {
Some(p) => {
warning!("Cannot find {} in current dir, find: {}", BUILD_JSON, p);
Some(p)
},
None => {
failure!("Cannot find {}", BUILD_JSON);
None
},
if let Some(p) = find_build_json_in_current() {
return Some(p);
}
match find_build_json_in_parents() {
Some(p) => {
warning!("Cannot find {} in current dir, find: {}", BUILD_JSON, p);
Some(p)
},
None => {
failure!("Cannot find {}", BUILD_JSON);
None
},
}
}