(
&self,
request: CustomFetchRequest,
)
| 37 | #[async_trait] |
| 38 | impl CustomFetchProxy for PluginBridgeFetchProxy { |
| 39 | async fn fetch( |
| 40 | &self, |
| 41 | request: CustomFetchRequest, |
| 42 | ) -> Result<CustomFetchResponse, ProviderError> { |
| 43 | let response = self |
| 44 | .bridge |
| 45 | .fetch_proxy(PluginFetchRequest { |
| 46 | url: request.url, |
| 47 | method: request.method, |
| 48 | headers: request.headers, |
| 49 | body: request.body, |
| 50 | }) |
| 51 | .await |
| 52 | .map_err(|e| ProviderError::NetworkError(e.to_string()))?; |
| 53 | |
| 54 | Ok(CustomFetchResponse { |
| 55 | status: response.status, |
| 56 | headers: response.headers, |
| 57 | body: response.body, |
| 58 | }) |
| 59 | } |
| 60 | |
| 61 | async fn fetch_stream( |
| 62 | &self, |
nothing calls this directly
no test coverage detected