Add more debug logging for better troubleshooting

Signed-off-by: Daniel D’Aquino <daniel@daquino.me>
This commit is contained in:
Daniel D’Aquino
2024-08-02 16:34:21 -07:00
parent db088b1aa3
commit 697bd4eb83
2 changed files with 6 additions and 0 deletions

View File

@ -18,6 +18,11 @@ impl MuteManager {
event: &Event,
pubkey: &PublicKey,
) -> bool {
log::debug!(
"Checking if event {:?} should be muted for pubkey {:?}",
event,
pubkey
);
if let Some(mute_list) = self.get_public_mute_list(pubkey).await {
for tag in mute_list.tags() {
match tag.kind() {

View File

@ -132,6 +132,7 @@ impl NotificationManager {
);
let one_week_ago = nostr::Timestamp::now() - 7 * 24 * 60 * 60;
if event.created_at < one_week_ago {
log::debug!("Event is older than a week, not sending notifications");
return Ok(());
}