remove old hash from map

This commit is contained in:
Chee Yee
2023-08-30 13:37:17 -07:00
parent d26baf817e
commit 529d88af06
+1
View File
@@ -62,5 +62,6 @@ std::string FileHost::GetCachedDownloadUrl(std::string &hash)
void FileHost::AddCacheDownloadUrl(std::string &hash, std::string &url)
{
std::pair<std::string, std::string> pair = std::make_pair(hash, url);
cache_downloal_urls.erase(hash);
cache_downloal_urls.insert(pair);
}