Skip to content

Commit

Permalink
Merge pull request #79 from aliziauddin/screener-page-count
Browse files Browse the repository at this point in the history
  • Loading branch information
lit26 committed Jul 2, 2023
2 parents 9a028c2 + e5b011c commit d8e42cd
Showing 1 changed file with 3 additions and 1 deletion.
4 changes: 3 additions & 1 deletion finvizfinance/screener/overview.py
Original file line number Diff line number Diff line change
Expand Up @@ -34,6 +34,7 @@ def __init__(self):
v_page=self.v_page, signal="", filter="", ticker=""
)
self._load_setting()
self.page_count = None

def _load_setting(self):
"""load all the signals and filters."""
Expand Down Expand Up @@ -173,7 +174,8 @@ def _get_page(self, soup):
"""Check the page number"""
try:
options = soup.find(id="pageSelect").findAll("option")
return len(options)
self.page_count = len(options)
return self.page_count
except:
return 0

Expand Down

0 comments on commit d8e42cd

Please sign in to comment.