Skip to content

Commit

Permalink
rename parameter
Browse files Browse the repository at this point in the history
  • Loading branch information
vorostamas committed Oct 25, 2023
1 parent 5df28eb commit 0513633
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions lidlplus/api.py
Original file line number Diff line number Diff line change
Expand Up @@ -238,7 +238,7 @@ def _default_headers(self):
"Accept-Language": self._language,
}

def tickets(self, onlyFavorite=False):
def tickets(self, only_favorite=False):
"""
Get a list of all tickets.
Expand All @@ -249,7 +249,7 @@ def tickets(self, onlyFavorite=False):
"""
url = f"{self._TICKET_API}/{self._country}/tickets"
kwargs = {"headers": self._default_headers(), "timeout": self._TIMEOUT}
ticket = requests.get(f"{url}?pageNumber=1&onlyFavorite={onlyFavorite}", **kwargs).json()
ticket = requests.get(f"{url}?pageNumber=1&onlyFavorite={only_favorite}", **kwargs).json()
tickets = ticket["tickets"]
for i in range(2, int(ticket["totalCount"] / ticket["size"] + 2)):
tickets += requests.get(f"{url}?pageNumber={i}", **kwargs).json()["tickets"]
Expand Down

0 comments on commit 0513633

Please sign in to comment.