public function addRateLimitHeaders($response, $limit, $remaining, $reset)
    {
        if ($this->enableRateLimitHeaders) {
            $response->setHeader('X-Rate-Limit-Limit', $limit);
            $response->setHeader('X-Rate-Limit-Remaining', $remaining);
            $response->setHeader('X-Rate-Limit-Reset', $reset);
        }
    }
public function addRateLimitHeaders($response, $limit, $remaining, $reset)
    {
        if ($this->enableRateLimitHeaders) {
            $response->setHeader('X-Rate-Limit-Limit', $limit);
            $response->setHeader('X-Rate-Limit-Remaining', $remaining);
            $response->setHeader('X-Rate-Limit-Reset', $reset);
        }
    }
public function addRateLimitHeaders ( $ response , $ limit , $ remaining , $ reset ) { if ( $ this -> enableRateLimitHeaders ) { $ response -> setHeader ( 'X-Rate-Limit-Limit' , $ limit ) ; $ response -> setHeader ( 'X-Rate-Limit-Remaining' , $ remaining ) ; $ response -> setHeader ( 'X-Rate-Limit-Reset' , $ reset ) ; } }
Adds the rate limit headers to the response.
@param Response $response
@param int $limit the maximum number of allowed requests during a period
@param int $remaining the remaining number of allowed requests within the current period
@param int $reset the number of seconds to wait before having maximum number of allowed requests again
Adds the rate limit headers to the response .