Skip to content

Commit

Permalink
share_post: Don't read summary as it's not used anywhere
Browse files Browse the repository at this point in the history
Related to issue getpelican#314.
  • Loading branch information
kernc committed Jul 12, 2015
1 parent 7747a4d commit fcdab23
Showing 1 changed file with 0 additions and 5 deletions.
5 changes: 0 additions & 5 deletions share_post/share_post.py
Expand Up @@ -27,16 +27,11 @@ def article_url(content):
return quote(('%s/%s' % (site_url, content.url)).encode('utf-8'))


def article_summary(content):
return quote(BeautifulSoup(content.summary, 'html.parser').get_text().strip().encode('utf-8'))


def share_post(content):
if isinstance(content, contents.Static):
return
title = article_title(content)
url = article_url(content)
summary = article_summary(content)

tweet = ('%s%s%s' % (title, quote(' '), url)).encode('utf-8')
diaspora_link = 'https://sharetodiaspora.github.io/?title=%s&url=%s' % (title, url)
Expand Down

0 comments on commit fcdab23

Please sign in to comment.