Skip to content

Commit

Permalink
Mer linting
Browse files Browse the repository at this point in the history
  • Loading branch information
erikaas24 committed Oct 21, 2024
1 parent b8c4a2f commit e0e5481
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion backend/apps/ecommerce/resolvers.py
Original file line number Diff line number Diff line change
Expand Up @@ -48,7 +48,7 @@ def resolve_paginated_shop_orders(self, info, limit, offset):
orders = orders[offset:]

Check warning on line 48 in backend/apps/ecommerce/resolvers.py

View check run for this annotation

Codecov / codecov/patch

backend/apps/ecommerce/resolvers.py#L46-L48

Added lines #L46 - L48 were not covered by tests

if limit is None or limit > 300:

Check warning on line 50 in backend/apps/ecommerce/resolvers.py

View check run for this annotation

Codecov / codecov/patch

backend/apps/ecommerce/resolvers.py#L50

Added line #L50 was not covered by tests
#Add hard cap of maximum 300 orders per query. A bigger query would crash the website
# Add hard cap of maximum 300 orders per query. A bigger query would crash the website
limit = 300
orders = orders[:limit]
return orders

Check warning on line 54 in backend/apps/ecommerce/resolvers.py

View check run for this annotation

Codecov / codecov/patch

backend/apps/ecommerce/resolvers.py#L52-L54

Added lines #L52 - L54 were not covered by tests
Expand Down

0 comments on commit e0e5481

Please sign in to comment.