Skip to content

Commit 904bf44

Browse files
committed
Simplify.
1 parent 49709b5 commit 904bf44

File tree

1 file changed

+3
-3
lines changed

1 file changed

+3
-3
lines changed

src/http/client.rs

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -87,7 +87,7 @@ impl Client {
8787
pin_project! {
8888
struct IncomingResponseFuture {
8989
#[pin]
90-
subscription: Option<WaitFor>,
90+
subscription: WaitFor,
9191
wasi: WasiFutureIncomingResponse,
9292
}
9393
}
@@ -96,7 +96,7 @@ impl Client {
9696

9797
fn poll(self: Pin<&mut Self>, cx: &mut Context<'_>) -> Poll<Self::Output> {
9898
let this = self.project();
99-
match this.subscription.as_pin_mut().expect("make it so").poll(cx) {
99+
match this.subscription.poll(cx) {
100100
Poll::Pending => Poll::Pending,
101101
Poll::Ready(()) => Poll::Ready(
102102
this.wasi
@@ -112,7 +112,7 @@ impl Client {
112112

113113
let subscription = AsyncPollable::new(res.subscribe()).wait_for();
114114
let future = IncomingResponseFuture {
115-
subscription: Some(subscription),
115+
subscription,
116116
wasi: res,
117117
};
118118

0 commit comments

Comments
 (0)