Skip to content

provide a default_per_page setting #1362

Open
@wolvever

Description

@wolvever

In this code https://github.com/pallets-eco/flask-sqlalchemy/blob/main/src/flask_sqlalchemy/pagination.py#L132

When per_page = 0, it will be set to 20 if error_out = False.

        if per_page < 1:
            if error_out:
                abort(404)
            else:
                per_page = 20

20 might not be the case for all scenarioes, better give it a configurable value.

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions