1
0
mirror of https://github.com/Unleash/unleash.git synced 2024-10-18 20:09:08 +02:00

fix: adjust page limit normalization (#5672)

This commit is contained in:
Jaanus Sellin 2023-12-18 14:33:45 +02:00 committed by GitHub
parent 3b635132f9
commit d0facc7101
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23

View File

@ -105,7 +105,7 @@ export default class FeatureSearchController extends Controller {
['enabled', 'disabled'].includes(tag[1]),
);
const normalizedLimit =
Number(limit) > 0 && Number(limit) <= 50 ? Number(limit) : 100;
Number(limit) > 0 && Number(limit) <= 100 ? Number(limit) : 25;
const normalizedOffset = Number(offset) > 0 ? Number(offset) : 0;
const normalizedSortBy: string = sortBy ? sortBy : 'createdAt';
const normalizedSortOrder =