1
0
Fork 0
mirror of https://github.com/ton-blockchain/ton synced 2025-03-09 15:40:10 +00:00

Improve dht lookup in overlays (#1104)

Continue dht lookup even if value was found
This commit is contained in:
SpyCheese 2024-08-15 15:26:35 +03:00 committed by GitHub
parent 77a816e461
commit 9661676646
No known key found for this signature in database
GPG key ID: B5690EEEBB952194
8 changed files with 127 additions and 35 deletions

View file

@ -555,6 +555,12 @@ class Result {
};
return status_.move_as_error_suffix(suffix);
}
Status move_as_status() TD_WARN_UNUSED_RESULT {
if (status_.is_error()) {
return move_as_error();
}
return Status::OK();
}
const T &ok() const {
LOG_CHECK(status_.is_ok()) << status_;
return value_;