Fix ArgumentNullException in GetDigitalGiftCards() (#893)

This commit is contained in:
Vital7
2018-09-01 09:46:33 +03:00
committed by Łukasz Domeradzki
parent 4084f489d3
commit a08cc48fcd

View File

@@ -472,6 +472,10 @@ namespace ArchiSteamFarm {
}
HtmlNodeCollection htmlNodes = response.DocumentNode.SelectNodes("//div[@class='pending_gift']/div[starts-with(@id, 'pending_gift_')][count(div[@class='pending_giftcard_leftcol']) > 0]/@id");
if (htmlNodes == null) {
return null;
}
HashSet<ulong> results = new HashSet<ulong>();
foreach (string gidText in htmlNodes.Select(node => node.GetAttributeValue("id", null))) {
if (string.IsNullOrEmpty(gidText)) {