skip bogus links in articles

workspace
Brendan Howell 7 years ago
parent 05f1558e85
commit a1553b965a

@ -147,7 +147,10 @@ class Publications(Bureau):
notecount = 0
# store links then make corresponding svg barcodes
for link in html.findall(".//a"):
notecount += 1
if "href" in link.attrib:
notecount += 1
else:
continue # skip bogus links
tmpcode = self._make_shorturl(link.attrib["href"])
svg = code128.svg("PBr." + tmpcode)

Loading…
Cancel
Save