use <link> tag to extract the relative post url, fixes #37

The <id> tag does not necessarily contains the full URL, but also
relative URLs:

    <id>http://example.com/foo/bar.html</id>
    <id>/foo/bar.html</id>
    <id>foo/bar.html</id>
legacy/0.5
Martin Zimmermann 11 years ago
parent 89ffe98106
commit 5e7ee3dffd

@ -30,7 +30,7 @@ comments = set([])
def insert(db, thread, posts):
path = urlparse(thread.find('%sid' % ns).text).path
path = urlparse(thread.find('%slink' % ns).text).path
remap = dict()
if path not in db.threads:

Loading…
Cancel
Save