From e1fcf64f322cc27f0c8677299629ab55917dfc01 Mon Sep 17 00:00:00 2001 From: Galileo Daras Date: Thu, 30 Jan 2025 11:05:37 -0800 Subject: [PATCH] chore(cellcom): 1984 orwellian reviewers --- cellcom/src/backend/status.rs | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) diff --git a/cellcom/src/backend/status.rs b/cellcom/src/backend/status.rs index 95e483a..af5ea1c 100644 --- a/cellcom/src/backend/status.rs +++ b/cellcom/src/backend/status.rs @@ -54,7 +54,6 @@ struct CellDataV2 { pub signal_strength: Option, } - pub fn client() -> &'static Client { static CLIENT: OnceLock = OnceLock::new(); CLIENT.get_or_init(|| { @@ -78,13 +77,15 @@ pub fn get_location( ); let backend = Backend::from_env()?; + // TODO: Some sort of actual response besides the status code // maybe one that includes the location? (requires changes on the // backend) let _response_raw = client() .post(EndpointsV2::new(backend, orb_id).status) .json(&request) - .send()?; + .send()? + .error_for_status()?; Ok(()) }