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

chore(notifications): make push msg optional #4341

Merged
merged 1 commit into from
Apr 23, 2024

Conversation

UncleSamtoshi
Copy link
Contributor

@UncleSamtoshi UncleSamtoshi commented Apr 23, 2024

  • Make push optional for notifications

&self,
_locale: GaloyLocale,
) -> Option<LocalizedStatefulMessage> {
None
Copy link
Member

Choose a reason for hiding this comment

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

This is the wrong way. The interface should encapsulate the contract of the should method is true we always return the message. Anything else is an implementation bug that is ok to crash (since it should never happen).

So if you refactor remove the other options instead of adding this one.

Copy link
Contributor Author

Choose a reason for hiding this comment

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

Makes sense, I will make the change

@UncleSamtoshi UncleSamtoshi force-pushed the notifications-optional-channels branch from 1820e64 to dc0423d Compare April 23, 2024 18:36
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants