Remove unused code to fix cargo warnings

Signed-off-by: Daniel D’Aquino <daniel@daquino.me>
This commit is contained in:
Daniel D’Aquino
2024-08-02 10:24:25 -07:00
parent 8d5c9475ab
commit daa2408cfd
2 changed files with 1 additions and 17 deletions

View File

@ -2,7 +2,6 @@ use super::ExtendedEvent;
use nostr_sdk::prelude::*;
pub struct MuteManager {
relay_url: String,
client: Client,
}
@ -11,7 +10,7 @@ impl MuteManager {
let client = Client::new(&Keys::generate());
client.add_relay(relay_url.clone()).await?;
client.connect().await;
Ok(MuteManager { relay_url, client })
Ok(MuteManager { client })
}
pub async fn should_mute_notification_for_pubkey(

View File

@ -19,10 +19,6 @@ use std::fs::File;
pub struct NotificationManager {
db: r2d2::Pool<SqliteConnectionManager>,
apns_private_key_path: String,
apns_private_key_id: String,
apns_team_id: String,
apns_environment: a2::client::Endpoint,
apns_topic: String,
apns_client: Client,
@ -56,10 +52,6 @@ impl NotificationManager {
)?;
Ok(Self {
apns_private_key_path,
apns_private_key_id,
apns_team_id,
apns_environment,
apns_topic,
apns_client: client,
db,
@ -209,13 +201,6 @@ impl NotificationManager {
Ok(relevant_pubkeys)
}
fn pubkeys_subscribed_to_event(
&self,
event: &Event,
) -> Result<HashSet<PublicKey>, Box<dyn std::error::Error>> {
self.pubkeys_subscribed_to_event_id(&event.id)
}
fn pubkeys_subscribed_to_event_id(
&self,
event_id: &EventId,