Incorrect repository pagination for PaginatedTree response
Description
For project with many directories the next pagination page contains the same list of directories
Project example: https://gitlab.com/pslaughter/test-2-.project
PaginatedTree response has the same value for startCursor and endCursor.
Maybe related: !66751 (diffs) and gitaly!3611 (diffs)