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

feat: mark all as read endpoint #431

Merged
merged 1 commit into from
Mar 22, 2024
Merged

Conversation

chris13524
Copy link
Member

Description

Implements the /mark-all-as-read endpoint as per the docs

Resolves #428

How Has This Been Tested?

New tests

Due Diligence

  • Breaking change
  • Requires a documentation update
  • Requires a e2e/integration test update

@chris13524 chris13524 self-assigned this Mar 21, 2024
Ok(StatusCode::NO_CONTENT.into_response())
}

pub async fn mark_all_as_read_rate_limit(
Copy link
Contributor

Choose a reason for hiding this comment

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

Is there any reason to make this single call in a function? Since it's just used once and just called another function inside?

Copy link
Member Author

Choose a reason for hiding this comment

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

It's just a pattern I've been doing when copying endpoints. Sometimes I test the rate limit. It's nice to have the config bundled here so you can see clearly what parameters are involved. No strong reason though

Choose a reason for hiding this comment

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

I think it's also nice that it keeps biz logic separate from auxiliary processes and gives you a tidy view of what the main function is supposed to do.

Copy link
Contributor

Choose a reason for hiding this comment

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

Just let's keep it simple if we can 🙌

@chris13524 chris13524 merged commit 9aa1fe7 into main Mar 22, 2024
13 checks passed
@chris13524 chris13524 deleted the feat/mark-all-as-read-endpoint branch March 22, 2024 16:42
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.

feat: mark all notifications as read endpoint
3 participants