Browse Source

consider 'link' not being in the list

David 9 năm trước cách đây
mục cha
commit
309673f371
1 tập tin đã thay đổi với 1 bổ sung1 xóa
  1. 1 1
      linklist.py

+ 1 - 1
linklist.py

@@ -14,7 +14,7 @@ class LinkList():
                 print(url)
                 print("RSS ERROR. PANIC")
             # print(feed["bozo"]) FIXME: If bozo==1 => error
-            self.links = [i["link"] for i in feed["items"]]
+            self.links = [i["link"] for i in feed["items"] if "link" in i ]
         else:
 
             if selector is None or selector == "":