Fix custom HTTP headers being ignored when using HTTPTileDataSource
@@ -99,11 +99,10 @@ namespace carto {
}
std::string url = buildTileURL(baseURL, mapTile);
Log::Infof("HTTPTileDataSource::loadTile: Loading %s", url.c_str());
- std::map<std::string, std::string> requestHeaders;
std::map<std::string, std::string> responseHeaders;
std::shared_ptr<BinaryData> responseData;
try {
- if (_httpClient.get(url, requestHeaders, responseHeaders, responseData) != 0) {
+ if (_httpClient.get(url, headers, responseHeaders, responseData) != 0) {
Log::Errorf("HTTPTileDataSource::loadTile: Failed to load %s", url.c_str());
return std::shared_ptr<TileData>();
}
