Skip to content

Commit

Permalink
fix: Handle limit parameter (#416)
Browse files Browse the repository at this point in the history
* fix: handle limit parameter

* fix: handle limit parameter
  • Loading branch information
hiohiohio authored Mar 11, 2024
1 parent f588e3d commit 11492c4
Show file tree
Hide file tree
Showing 3 changed files with 3 additions and 3 deletions.
2 changes: 1 addition & 1 deletion alpaca/data/historical/crypto.py
Original file line number Diff line number Diff line change
Expand Up @@ -367,7 +367,7 @@ def _data_get(

# if we've sent a request with a limit, increment count
if actual_limit:
total_items += actual_limit
total_items = sum([len(items) for items in data_by_symbol.values()])

page_token = response.get("next_page_token", None)

Expand Down
2 changes: 1 addition & 1 deletion alpaca/data/historical/option.py
Original file line number Diff line number Diff line change
Expand Up @@ -268,7 +268,7 @@ def _data_get(

# if we've sent a request with a limit, increment count
if actual_limit:
total_items += actual_limit
total_items = sum([len(items) for items in data_by_symbol.values()])

page_token = response.get("next_page_token", None)

Expand Down
2 changes: 1 addition & 1 deletion alpaca/data/historical/stock.py
Original file line number Diff line number Diff line change
Expand Up @@ -347,7 +347,7 @@ def _data_get(

# if we've sent a request with a limit, increment count
if actual_limit:
total_items += actual_limit
total_items = sum([len(items) for items in data_by_symbol.values()])

page_token = response.get("next_page_token", None)

Expand Down

0 comments on commit 11492c4

Please sign in to comment.