From f4555bd2fcaded9031b8aa72804c3dbd47ea6109 Mon Sep 17 00:00:00 2001 From: pabloroca Date: Mon, 29 Feb 2016 23:18:22 +0000 Subject: [PATCH] Update README.md --- README.md | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/README.md b/README.md index 498fb28..c3e3071 100644 --- a/README.md +++ b/README.md @@ -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;