Navigation Menu

Skip to content

Commit

Permalink
retrieve page text in try-except block
Browse files Browse the repository at this point in the history
  • Loading branch information
HazardSJ committed Feb 3, 2016
1 parent 1ffd2c3 commit b852924
Showing 1 changed file with 3 additions and 2 deletions.
5 changes: 3 additions & 2 deletions enwiki/afd_relisted_null_editor.py
Expand Up @@ -15,9 +15,10 @@ def __init__(self):

def process_log(self, log):
for page in log.itertemplates():
if page.title().startswith(self.afd_prefix) and self.category.title() in page.get():
if page.title().startswith(self.afd_prefix):
try:
page.touch()
if self.category.title() in page.get():
page.touch()
except pywikibot.Error:
pass

Expand Down

0 comments on commit b852924

Please sign in to comment.