Skip to content

Commit a9af9fc

Browse files
vilattometa-codesync[bot]
authored andcommitted
Fix deprecated code in Cpp2ConnContext
Summary: Before this change, when building from mac, I got the error complaining about deprecated method being used. Deprecated here: https://www.internalfb.com/code/fbsource/[1ea5ce7555c142cfe4d975e27c3855e987e49b95]/fbcode/thrift/lib/cpp2/FieldRef.h?lines=147-153 Reviewed By: iahs Differential Revision: D88436271 fbshipit-source-id: fdccba05ea31438ae0dfbc3150cf96a571869377
1 parent 0955d19 commit a9af9fc

1 file changed

Lines changed: 2 additions & 1 deletion

File tree

third-party/thrift/src/thrift/lib/cpp2/server/Cpp2ConnContext.h

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -781,7 +781,8 @@ class Cpp2RequestContext : public apache::thrift::server::TConnectionContext {
781781
if (auto* header = getHeader()) {
782782
if (const auto& loggingContext = header->loggingContext()) {
783783
if (const auto attemptIdRef = loggingContext->requestAttemptId();
784-
attemptIdRef.is_set()) {
784+
apache::thrift::is_non_optional_field_set_manually_or_by_serializer(
785+
attemptIdRef)) {
785786
return *attemptIdRef;
786787
}
787788
}

0 commit comments

Comments
 (0)