protected function prepareData()
    {
        if (!empty($this->data)) {
            if ($this->method === HttpMethods::GET) {
                $this->url = Utils::appendUrlQuery($this->url, $this->data);
            } else if ($this->method === HttpMethods::POST) {
                curl_setopt($this->curl, CURLOPT_POSTFIELDS, $this->data);
            }
        }
    }
protected function prepareData()
    {
        if (!empty($this->data)) {
            if ($this->method === HttpMethods::GET) {
                $this->url = Utils::appendUrlQuery($this->url, $this->data);
            } else if ($this->method === HttpMethods::POST) {
                curl_setopt($this->curl, CURLOPT_POSTFIELDS, $this->data);
            }
        }
    }
protected function prepareData ( ) { if ( ! empty ( $ this -> data ) ) { if ( $ this -> method === HttpMethods :: GET ) { $ this -> url = Utils :: appendUrlQuery ( $ this -> url , $ this -> data ) ; } else if ( $ this -> method === HttpMethods :: POST ) { curl_setopt ( $ this -> curl , CURLOPT_POSTFIELDS , $ this -> data ) ; } } }
Adds the data value to the curl request
Adds the data value to the curl request