Skip to content

Commit

Permalink
fix: remove tower service if wasm32
Browse files Browse the repository at this point in the history
Signed-off-by: Gustavo Inacio <incio.gusta@gmail.com>
  • Loading branch information
gusinacio committed Jun 19, 2024
1 parent 88dbfe6 commit f6c7097
Showing 1 changed file with 2 additions and 0 deletions.
2 changes: 2 additions & 0 deletions reqwest-middleware/src/client.rs
Original file line number Diff line number Diff line change
Expand Up @@ -247,6 +247,7 @@ impl fmt::Debug for ClientWithMiddleware {
}
}

#[cfg(not(target_arch = "wasm32"))]
mod service {
use std::{
future::Future,
Expand Down Expand Up @@ -422,6 +423,7 @@ impl RequestBuilder {
/// The timeout is applied from when the request starts connecting until the
/// response body has finished. It affects only this request and overrides
/// the timeout configured using `ClientBuilder::timeout()`.
#[cfg(not(target_arch = "wasm32"))]
pub fn timeout(self, timeout: std::time::Duration) -> Self {
RequestBuilder {
inner: self.inner.timeout(timeout),
Expand Down

0 comments on commit f6c7097

Please sign in to comment.