mirror of
https://github.com/Sude-/lgogdownloader.git
synced 2024-11-20 03:39:17 +01:00
Fix item url in wishlist
This commit is contained in:
parent
5cdee34b99
commit
1ebbb81b07
@ -702,10 +702,13 @@ std::vector<wishlistItem> Website::getWishlistItems()
|
||||
item.store_credit = product["price"]["bonusStoreCreditAmount"].isDouble() ? std::to_string(product["price"]["bonusStoreCreditAmount"].asDouble()) + item.currency : product["price"]["bonusStoreCreditAmount"].asString() + item.currency;
|
||||
|
||||
item.url = product["url"].asString();
|
||||
if (item.url.find("/game/") == 0)
|
||||
item.url = "https://www.gog.com" + item.url;
|
||||
else if (item.url.find("/movie/") == 0)
|
||||
item.url = "https://www.gog.com" + item.url;
|
||||
if (!(item.url.find("http") == 0))
|
||||
{
|
||||
if (item.url.front() == '/')
|
||||
item.url = "https://www.gog.com" + item.url;
|
||||
else
|
||||
item.url = "https://www.gog.com/" + item.url;
|
||||
}
|
||||
|
||||
item.title = product["title"].asString();
|
||||
item.bIsBonusStoreCreditIncluded = product["price"]["isBonusStoreCreditIncluded"].asBool();
|
||||
|
Loading…
Reference in New Issue
Block a user