Skip to content

Commit

Permalink
Update README.md
Browse files Browse the repository at this point in the history
  • Loading branch information
pabloroca committed Feb 29, 2016
1 parent ab7502e commit f4555bd
Showing 1 changed file with 3 additions and 3 deletions.
6 changes: 3 additions & 3 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -38,10 +38,10 @@ $app->add(function ($request, $response, $next) {
$mustbethrottled = $APIRateLimit();

if ($mustbethrottled == false) {
$responsen = $next($request, $responsen);
$responsen = $next($request, $response);
} else {
$responsen = $responsen ->withStatus(429)
->withHeader('RateLimit-Limit', $requests);
$responsen = $response ->withStatus(429)
->withHeader('RateLimit-Limit', $requests);
}

return $responsen;
Expand Down

0 comments on commit f4555bd

Please sign in to comment.