1
0
mirror of https://github.com/luanti-org/luanti.git synced 2025-10-12 16:15:20 +02:00

Add PUT and DELETE request + specific method value to HTTP API (#9909)

This commit is contained in:
Lejo
2020-07-30 00:16:21 +03:00
committed by GitHub
parent f34abaedd2
commit 715a123a33
8 changed files with 98 additions and 44 deletions

View File

@@ -261,11 +261,11 @@ void sendAnnounce(AnnounceAction action,
HTTPFetchRequest fetch_request;
fetch_request.url = g_settings->get("serverlist_url") + std::string("/announce");
fetch_request.post_fields["json"] = fastWriteJson(server);
fetch_request.method = HTTP_POST;
fetch_request.fields["json"] = fastWriteJson(server);
fetch_request.multipart = true;
httpfetch_async(fetch_request);
}
#endif
} // namespace ServerList