Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Timeout delay for notifications #665

Merged
merged 1 commit into from
Dec 26, 2024
Merged

Timeout delay for notifications #665

merged 1 commit into from
Dec 26, 2024

Conversation

englut
Copy link
Contributor

@englut englut commented Dec 6, 2024

Added timeout delay for direct message all notifications to prevent multiple simultaneous messages flooding with notification sounds.

Default is set to 500ms.
Addresses issue #600.

EDIT: Refactored for all notifications.

EDIT 2: I had looked into maybe turning Notifications into a trait. But I don't think that's what traits are meant for. So I'll leave it for now. If anyone has any suggestions for refactors or improvements, I am open 🙏

@englut englut force-pushed the main branch 2 times, most recently from 33c2486 to d1882ab Compare December 9, 2024 08:21
@englut englut changed the title Timeout delay for direct message notifications Timeout delay for notifications Dec 9, 2024
@englut englut force-pushed the main branch 3 times, most recently from 40254e3 to fcc4561 Compare December 16, 2024 15:42
@englut englut marked this pull request as draft December 17, 2024 18:04
@englut englut marked this pull request as ready for review December 17, 2024 21:52
src/notification.rs Outdated Show resolved Hide resolved
server,
);
}
fn _execute(
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

No need for the underscore naming here, imo.

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Removed!

src/notification.rs Outdated Show resolved Hide resolved
@casperstorm casperstorm merged commit a9fa38b into squidowl:main Dec 26, 2024
1 check passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants