mirror of
https://github.com/graphql-python/graphene-django.git
synced 2025-07-12 09:12:18 +03:00
Fix backward Relay pagination
This commit is contained in:
parent
b552dcac24
commit
ca80585636
|
@ -150,6 +150,10 @@ class DjangoConnectionField(ConnectionField):
|
|||
after = min(get_offset_with_default(args.get("after"), -1) + 1, list_length)
|
||||
|
||||
if max_limit is not None and "first" not in args:
|
||||
if "last" in args:
|
||||
args["first"] = list_length
|
||||
list_slice_length = list_length
|
||||
else:
|
||||
args["first"] = max_limit
|
||||
|
||||
connection = connection_from_list_slice(
|
||||
|
|
Loading…
Reference in New Issue
Block a user