Skip to content

fix: HasRateLimits counts cached responses against the rate limit - #30

Merged
Sammyjo20 merged 5 commits into
saloonphp:v2from
maks-oleksyuk:fix/skip-rate-limit-for-cache-hits
Oct 15, 2026
Merged

Sammyjo20 merged 5 commits into
saloonphp:v2from
maks-oleksyuk:fix/skip-rate-limit-for-cache-hits

Conversation

@maks-oleksyuk

Copy link
Copy Markdown
Contributor

When HasCaching and HasRateLimits are used together, cache hits are incorrectly counted toward the limit. This causes delays even when no actual API requests have been made.

@maks-oleksyuk

maks-oleksyuk commented Apr 27, 2026 •

Copy link
Copy Markdown
Contributor Author

fixes saloonphp/saloon#519

@maks-oleksyuk

Copy link
Copy Markdown
Contributor Author

@Sammyjo20, can you review this?

@Sammyjo20

Copy link
Copy Markdown
Member

Hey @maks-oleksyuk I will review it for you within the next couple of weeks.

Comment thread src/Traits/HasRateLimits.php Outdated
Comment thread src/Traits/HasRateLimits.php Outdated
@Sammyjo20
Sammyjo20 merged commit 180c3f7 into saloonphp:v2 Oct 15, 2026
26 checks passed
@Sammyjo20

Copy link
Copy Markdown
Member

Thanks @maks-oleksyuk

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