Skip to content

Commit

Permalink
fix: other changes
Browse files Browse the repository at this point in the history
Signed-off-by: IAmTomahawkx <iamtomahawkx@gmail.com>
  • Loading branch information
IAmTomahawkx committed Nov 27, 2024
1 parent 63c7494 commit 457683e
Show file tree
Hide file tree
Showing 2 changed files with 0 additions and 29 deletions.
10 changes: 0 additions & 10 deletions crates/daemons/pushd/src/consumers/inbound/internal.rs
Original file line number Diff line number Diff line change
Expand Up @@ -43,19 +43,9 @@ pub(crate) async fn publish_message<T: Channeled>(
}

if let Some(chnl) = channel {
//if let Err(err) =
chnl.basic_publish(BasicProperties::default(), payload.clone(), args.clone())
.await
.unwrap();
// {
// match err {
// Error::InternalChannelError(_) => {
// self.make_channel().await;
// self.publish_message(payload, args, attempt + 1).await;
// }
// _ => {}
// }
// }
debug!("Sent message to queue for target {}", routing_key);
} else {
warn!("Failed to unwrap channel (including attempt to make a channel)!")
Expand Down
19 changes: 0 additions & 19 deletions crates/daemons/pushd/src/consumers/outbound/vapid.rs
Original file line number Diff line number Diff line change
Expand Up @@ -20,25 +20,6 @@ pub struct VapidOutboundConsumer {
pkey: Vec<u8>,
}

// impl VapidOutboundConsumer {
// fn format_title(&self, notification: &PushNotification) -> String {
// // ideally this changes depending on context
// // in a server, it would look like "Sendername, #channelname in servername"
// // in a group, it would look like "Sendername in groupname"
// // in a dm it should just be "Sendername".
// // not sure how feasible all those are given the PushNotification object as it currently stands.

// match &notification.channel {
// Channel::DirectMessage { .. } => notification.author.clone(),
// Channel::Group { name, .. } => format!("{}, #{}", notification.author, name),
// Channel::TextChannel { name, .. } | Channel::VoiceChannel { name, .. } => {
// format!("{} in #{}", notification.author, name)
// }
// _ => "Unknown".to_string(),
// }
// }
// }

impl VapidOutboundConsumer {
pub async fn new(db: Database) -> Result<VapidOutboundConsumer, &'static str> {
let config = revolt_config::config().await;
Expand Down

0 comments on commit 457683e

Please sign in to comment.