summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--src/buildtool/execution_api/local/local_storage.cpp12
1 files changed, 5 insertions, 7 deletions
diff --git a/src/buildtool/execution_api/local/local_storage.cpp b/src/buildtool/execution_api/local/local_storage.cpp
index b4fe1658..c007fc1d 100644
--- a/src/buildtool/execution_api/local/local_storage.cpp
+++ b/src/buildtool/execution_api/local/local_storage.cpp
@@ -104,13 +104,11 @@ auto LocalStorage::ReadObjectInfosRecursively(
return BazelMsgFactory::ReadObjectInfosFromDirectory(
*dir,
[this, &store_info, &parent, &tree](auto path, auto info) {
- return IsTreeObject(info.type)
- ? (not tree or tree->AddInfo(path, info)) and
- ReadObjectInfosRecursively(
- store_info,
- parent / path,
- info.digest)
- : store_info(parent / path, info);
+ return (not tree or tree->AddInfo(path, info)) and
+ (IsTreeObject(info.type)
+ ? ReadObjectInfosRecursively(
+ store_info, parent / path, info.digest)
+ : store_info(parent / path, info));
}) and
(not tree_map_ or tree_map_->AddTree(digest, std::move(*tree)));
}