Skip to content

Commit

Permalink
Algos: simplify and_then call (#1096)
Browse files Browse the repository at this point in the history
  • Loading branch information
ken-matsui authored Jan 15, 2025
1 parent 7b5a110 commit 455d04d
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion src/Algos.cc
Original file line number Diff line number Diff line change
Expand Up @@ -90,7 +90,7 @@ commandExists(const std::string_view cmd) noexcept {
.addArg(cmd)
.setStdOutConfig(Command::IOConfig::Null)
.spawn()
.and_then([](const auto child) { return child.wait(); })
.and_then(&Child::wait)
.map([](const int exitCode) { return exitCode == 0; })
.unwrap_or(false);
}
Expand Down

0 comments on commit 455d04d

Please sign in to comment.