diff --git a/src/WbApiClient.php b/src/WbApiClient.php index d563e5a..2acd6ef 100644 --- a/src/WbApiClient.php +++ b/src/WbApiClient.php @@ -189,7 +189,6 @@ protected function sendRequest( string $path, string $method = 'GET', array $dat if ( empty( $this->token ) ) { return $this->handleError( 'The Token is not specified' ); } - if ( !isset( $data['dateFrom'] ) ) { return $this->handleError( 'The dateFrom parameter is not specified' ); } @@ -245,7 +244,7 @@ protected function sendRequest( string $path, string $method = 'GET', array $dat $curlErrors = curl_error( $this->curl ); $curlInfo = curl_getinfo( $this->curl ); - $ip = $curlInfo['primary_ip']; + $ipAddress = $curlInfo['primary_ip']; $header_size = $curlInfo['header_size']; $headerCode = $curlInfo['http_code']; $responseHeaders = trim( substr( $response, 0, $header_size ) ); @@ -272,7 +271,7 @@ protected function sendRequest( string $path, string $method = 'GET', array $dat $retval->data = $responseBody; $retval->http_code = $headerCode; $retval->headers = $responseHeaders; - $retval->ip = $ip; + $retval->ip = $ipAddress; $retval->curlErrors = $curlErrors; $retval->method = $method . ':' . $url; $retval->timestamp = date( DATE_RFC3339 );