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

NewRedisLimitCounter: no error to return #21

Merged
merged 3 commits into from
Oct 23, 2024

Conversation

klaidliadon
Copy link
Contributor

NewRedisLimitCounter used to return an error when trying to pin, but that is not the case anymore. Let's remove the error from the return arguments to simplify the code.

Copy link
Contributor

@VojtechVitek VojtechVitek left a comment

Choose a reason for hiding this comment

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

@klaidliadon This is a breaking change. I mean, no big deal -- but I'd probably prefer to keep the API backwards-compatible.

How about we add a new function that doesn't return the error and we let users switch to it?
e.g. httprateredis.NewCounter()

Copy link
Contributor

@VojtechVitek VojtechVitek left a comment

Choose a reason for hiding this comment

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

LGTM

@VojtechVitek VojtechVitek merged commit 8710645 into go-chi:master Oct 23, 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