From 5b9fd8e4a7b8344d1be59acd57bd54b79a11324c Mon Sep 17 00:00:00 2001 From: Jim Miller Date: Sun, 30 Oct 2016 11:43:14 -0500 Subject: [PATCH] Fix for potterfics.com layout change. --- fanficfare/adapters/adapter_potterficscom.py | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/fanficfare/adapters/adapter_potterficscom.py b/fanficfare/adapters/adapter_potterficscom.py index 9dc89d80..597abe6e 100644 --- a/fanficfare/adapters/adapter_potterficscom.py +++ b/fanficfare/adapters/adapter_potterficscom.py @@ -182,8 +182,8 @@ class PotterFicsComAdapter(BaseSiteAdapter): #we want the second table directly under the body, contains all the metadata table = soup.html.body.findAll('table', recursive=False)[1] - #within that, we want the second row, first cell - cell = table.tr.findNextSibling('tr').td + #within that, we want the first row, three cell + cell = table.tr.find_all('td')[2] #find first metadata block--isn't first if logged in mb = cell.div.findNextSibling('div',{'align':'left'})