Fix for AO3 story list URLs that already have a '?' in them.

This commit is contained in:
Jim Miller 2014-09-11 11:46:44 -05:00
parent 4819ca95b1
commit 79971745a2

View file

@ -43,7 +43,10 @@ def get_urls_from_page(url,configuration=None,normalize=False):
if 'archiveofourown.org' in url:
if adapter.getConfig("username"):
if adapter.getConfig("is_adult"):
addurl = "?view_adult=true"
if '?' in url:
addurl = "&view_adult=true"
else:
addurl = "?view_adult=true"
else:
addurl=""
# just to get an authenticity_token.