Skip to content

items-per-page=0 in the URL empties the file list #4196

Closed

Description

@AlexAndBear

Initial Checklist

  • I understand this is a bug report and questions should be posted in the Community Discussions
  • I searched issues and couldn’t find anything (or linked relevant results below)

Bug Description

items-per-page=0 in the URL empties the file list and throws page errors, and -1 hides the last item. usePagination.ts only falls back to the default for NaN.

Reproduction Steps

  1. Open a folder with 5 files and ?items-per-page=0
  2. Then open it with items-per-page=-1

Expected Outcome

Invalid values are ignored and the default is used.

Actual Outcome

With 0 the list is empty with Invalid array length page errors. With -1 only 4 of 5 files show.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

Labels

Type

No type

Projects

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions