1
1
Fork 0
mirror of https://github.com/NixOS/nix.git synced 2025-11-09 03:56:01 +01:00

DownloadRequest -> DataTransferRequest

This commit is contained in:
Nikola Knezevic 2020-04-06 13:30:45 +02:00
parent 5449ff7d8a
commit 65ef57e0cb
6 changed files with 19 additions and 20 deletions

View file

@ -85,7 +85,7 @@ protected:
checkEnabled();
try {
DownloadRequest request(cacheUri + "/" + path);
DataTransferRequest request(cacheUri + "/" + path);
request.head = true;
getDownloader()->download(request);
return true;
@ -103,7 +103,7 @@ protected:
const std::string & data,
const std::string & mimeType) override
{
auto req = DownloadRequest(cacheUri + "/" + path);
auto req = DataTransferRequest(cacheUri + "/" + path);
req.data = std::make_shared<string>(data); // FIXME: inefficient
req.mimeType = mimeType;
try {
@ -113,9 +113,9 @@ protected:
}
}
DownloadRequest makeRequest(const std::string & path)
DataTransferRequest makeRequest(const std::string & path)
{
DownloadRequest request(cacheUri + "/" + path);
DataTransferRequest request(cacheUri + "/" + path);
return request;
}