Skip to content

Commit 5d579c6

Browse files
committed
feat: expose Status as a Response extension
1 parent 6839a39 commit 5d579c6

File tree

1 file changed

+1
-0
lines changed

1 file changed

+1
-0
lines changed

tonic/src/status.rs

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -580,6 +580,7 @@ impl Status {
580580
.headers_mut()
581581
.insert(http::header::CONTENT_TYPE, GRPC_CONTENT_TYPE);
582582
self.add_header(response.headers_mut()).unwrap();
583+
response.extensions_mut().insert(self);
583584
response
584585
}
585586

0 commit comments

Comments
 (0)