protected function _getRateLimitInfo($headers)
  {
    if (! isset($headers['x-rate-limit-limit'])) {
      return null;
    }
    $rate = [
      'limit'     => $headers['x-rate-limit-limit'],
      'remaining' => $headers['x-rate-limit-remaining'],
      'reset'     => $headers['x-rate-limit-reset']
    ];
    if ($this->_return_format === CODEBIRD_RETURNFORMAT_OBJECT) {
      return (object) $rate;
    }
    return $rate;
  }
protected function _getRateLimitInfo($headers)
  {
    if (! isset($headers['x-rate-limit-limit'])) {
      return null;
    }
    $rate = [
      'limit'     => $headers['x-rate-limit-limit'],
      'remaining' => $headers['x-rate-limit-remaining'],
      'reset'     => $headers['x-rate-limit-reset']
    ];
    if ($this->_return_format === CODEBIRD_RETURNFORMAT_OBJECT) {
      return (object) $rate;
    }
    return $rate;
  }
protected function _getRateLimitInfo ( $ headers ) { if ( ! isset ( $ headers [ 'x-rate-limit-limit' ] ) ) { return null ; } $ rate = [ 'limit' => $ headers [ 'x-rate-limit-limit' ] , 'remaining' => $ headers [ 'x-rate-limit-remaining' ] , 'reset' => $ headers [ 'x-rate-limit-reset' ] ] ; if ( $ this -> _return_format === CODEBIRD_RETURNFORMAT_OBJECT ) { return ( object ) $ rate ; } return $ rate ; }
Extract rate-limiting data from response headers

@param array $headers The CURL response headers

@return null|array|object The rate-limiting information
Extract rate - limiting data from response headers