Skip to content

Commit

Permalink
show todays news
Browse files Browse the repository at this point in the history
  • Loading branch information
MichaelKatsoulis committed May 6, 2018
1 parent 0f7f1ff commit 46c745d
Showing 1 changed file with 3 additions and 0 deletions.
3 changes: 3 additions & 0 deletions scrader_server.py
Original file line number Diff line number Diff line change
Expand Up @@ -926,6 +926,9 @@ def get_news(company, news_type, page_num, date):

LOG.info('quick_replies_page_numbers_to_show: {}'.\
format(quick_replies_page_numbers_to_show))
# quick replies cannot be over 11
if len(quick_replies_page_numbers_to_show) > 11:
quick_replies_page_numbers_to_show = quick_replies_page_numbers_to_show[:11]
for page_number in quick_replies_page_numbers_to_show:
quick_reply = copy.deepcopy(quick_reply)
quick_reply['title'] = "Page {}".format(page_number)
Expand Down

0 comments on commit 46c745d

Please sign in to comment.