Bureaucrats, Check users, Interface administrators, Push subscription managers, Suppressors, Administrators
435
edits
Explodabat (talk | contribs) No edit summary |
Explodabat (talk | contribs) No edit summary |
||
Line 130: | Line 130: | ||
//find price of the ship on the page using the infobox HTML | //find price of the ship on the page using the infobox HTML | ||
p = Array.from(pg.getElementsByTagName("td")).find(function(obj){ | p = Array.from(pg.getElementsByTagName("td")).find(function(obj){ | ||
return obj.getAttribute("data-source") !== null && obj.getAttribute("data-source").includes(" | return obj.getAttribute("data-source") !== null && obj.getAttribute("data-source").includes("total_cost"); | ||
}); | }); | ||
if(p === undefined) p = "N/A--"+name; | if(p === undefined) p = "N/A--"+name; |