summaryrefslogtreecommitdiff
path: root/src/client
diff options
context:
space:
mode:
authorlittleblack111 <littleblack11111@gmail.com>2025-09-21 22:59:47 +0800
committerlittleblack111 <littleblack11111@gmail.com>2025-09-21 22:59:47 +0800
commit2e1d12ec90ea12e8824d79dfc31b5b3cae397df8 (patch)
treefe052f73fcfa7d5bc195d74859a88a721bfd2520 /src/client
parent1a9961c778308fe2b043c980ba485a633e62d6cf (diff)
wip
Diffstat (limited to 'src/client')
-rw-r--r--src/client/connector.rs2
-rw-r--r--src/client/connector/httpconnector.rs2
2 files changed, 2 insertions, 2 deletions
diff --git a/src/client/connector.rs b/src/client/connector.rs
index 32c9cae..22a9f5a 100644
--- a/src/client/connector.rs
+++ b/src/client/connector.rs
@@ -73,7 +73,7 @@ pub trait Connection {
None => return,
};
// FIXME: handle the errors... peak prod code
- self.ntfy(Executor::new((task.try_into() as result::Result<Task, IntoTaskErr>).unwrap().as_ref(), it, ()).unwrap().run().as_ref().unwrap().clone()).unwrap();
+ self.ntfy(Executor::new((task.try_into() as result::Result<Task, IntoTaskErr>).unwrap().as_ref(), it, ()).run().as_ref().unwrap().clone()).unwrap();
}
Result::Err(e) => {
#[cfg(debug_assertions)]
diff --git a/src/client/connector/httpconnector.rs b/src/client/connector/httpconnector.rs
index d668ce5..67741e9 100644
--- a/src/client/connector/httpconnector.rs
+++ b/src/client/connector/httpconnector.rs
@@ -37,7 +37,7 @@ pub struct HTTPConnector {
impl HTTPConnector {
pub fn new(pull_url: &str, ntfy_url: &str, ip_getter_url: &str) -> result::Result<Self, HTTPConnectorError> {
Ok(Self {
- network_enforcer: Executor::new(NETWORK_T.as_ref(), ["true"], ()).unwrap(), // .unwrap() should never panic
+ network_enforcer: Executor::new(NETWORK_T.as_ref(), ["true"], ()), // .unwrap() should never panic
prev: String::new(),
pull_url: Url::parse(pull_url)?,
ntfy_url: Url::parse(ntfy_url)?,