Skip to content

Upstream changes#42

Merged
thehabes merged 4 commits into
mainfrom
upstream-changes
May 7, 2026
Merged

Upstream changes#42
thehabes merged 4 commits into
mainfrom
upstream-changes

Conversation

@cubap
Copy link
Copy Markdown
Member

@cubap cubap commented Apr 2, 2026

pulling in the changes made to TinyThings

cubap added 2 commits April 2, 2026 16:09
Implement getPagination in rest.js to parse, validate, and cap query limit/skip values (defaults, non-negative integer enforcement, env-configured maximums, throws 400 on malformed input). Export getPagination and add unit tests (__tests__/rest.test.js) covering defaults, parsing, error cases, and env caps. Update routes: use rest.getPagination in routes/query.js to derive limit/skip from req.query and use optional chaining for id checks in routes/overwrite.js and routes/update.js.
Implement getPagination in rest.js to parse, validate, and cap query limit/skip values (defaults, non-negative integer enforcement, env-configured maximums, throws 400 on malformed input). Export getPagination and add unit tests (__tests__/rest.test.js) covering defaults, parsing, error cases, and env caps. Update routes: use rest.getPagination in routes/query.js to derive limit/skip from req.query and use optional chaining for id checks in routes/overwrite.js and routes/update.js.
@cubap
Copy link
Copy Markdown
Member Author

cubap commented Apr 2, 2026

some of this might be redundant with #41, so be prepared to remove this

@thehabes thehabes merged commit e064e5f into main May 7, 2026
3 checks passed
@thehabes thehabes deleted the upstream-changes branch May 7, 2026 16:33
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants