Add support for HTTP method PUT.
This commit is contained in:
parent
1bfe3136aa
commit
fba5a576f0
|
@ -40,6 +40,7 @@ enum class http_method
|
|||
GET,
|
||||
POST,
|
||||
PATCH,
|
||||
PUT,
|
||||
DELETE
|
||||
};
|
||||
|
||||
|
|
|
@ -65,6 +65,12 @@ answer_type CURLWrapper::make_request(const http_method &method,
|
|||
code = curl_easy_setopt(_connection, CURLOPT_CUSTOMREQUEST, "PATCH");
|
||||
break;
|
||||
}
|
||||
case http_method::PUT:
|
||||
{
|
||||
// NOLINTNEXTLINE(cppcoreguidelines-pro-type-vararg)
|
||||
code = curl_easy_setopt(_connection, CURLOPT_UPLOAD, 1L);
|
||||
break;
|
||||
}
|
||||
case http_method::DELETE:
|
||||
{
|
||||
// NOLINTNEXTLINE(cppcoreguidelines-pro-type-vararg)
|
||||
|
|
Loading…
Reference in New Issue
Block a user