Skip to content

Commit

Permalink
Rate limiting
Browse files Browse the repository at this point in the history
- Switched to new rate limiting
  • Loading branch information
deanblackborough committed Jan 26, 2021
1 parent eac30cd commit 761d4e6
Show file tree
Hide file tree
Showing 2 changed files with 2 additions and 2 deletions.
2 changes: 1 addition & 1 deletion app/Http/Kernel.php
Original file line number Diff line number Diff line change
Expand Up @@ -37,7 +37,7 @@ class Kernel extends HttpKernel
],

'api' => [
'throttle:300,1',
'throttle:api',
'bindings'
],
];
Expand Down
2 changes: 1 addition & 1 deletion app/Providers/RouteServiceProvider.php
Original file line number Diff line number Diff line change
Expand Up @@ -56,7 +56,7 @@ public function boot()
protected function configureRateLimiting()
{
RateLimiter::for('api', function (Request $request) {
return Limit::perMinute(60)->by(optional($request->user())->id ?: $request->ip());
return Limit::perMinute(300)->by(optional($request->user())->id ?: $request->ip());
});
}
}

0 comments on commit 761d4e6

Please sign in to comment.