File tree Expand file tree Collapse file tree 3 files changed +5
-5
lines changed
Expand file tree Collapse file tree 3 files changed +5
-5
lines changed Original file line number Diff line number Diff line change 88| State | ` concepts/handlers.md ` | ` rustapi-core/src/extract.rs ` | OK |
99| Validation | ` crates/rustapi_validate.md ` | ` rustapi-validate ` | OK |
1010| ** HATEOAS** | | | |
11- | Pagination | ` recipes/pagination.md ` (Planned) | ` rustapi-core/src/hateoas.rs ` | ** Missing ** |
12- | Links | ` recipes/pagination.md ` (Planned) | ` rustapi-core/src/hateoas.rs ` | ** Missing ** |
11+ | Pagination | ` recipes/pagination.md ` | ` rustapi-core/src/hateoas.rs ` | OK |
12+ | Links | ` recipes/pagination.md ` | ` rustapi-core/src/hateoas.rs ` | OK |
1313| ** Extras** | | | |
1414| Auth (JWT) | ` recipes/jwt_auth.md ` | ` rustapi-extras/src/jwt ` | OK |
1515| Security | ` recipes/csrf_protection.md ` | ` rustapi-extras/src/security ` | OK |
1616| Observability | ` crates/rustapi_extras.md ` | ` rustapi-extras/src/telemetry ` | OK |
1717| ** Jobs** | | | |
1818| Job Queue | ` crates/rustapi_jobs.md ` | ` rustapi-jobs ` | OK |
1919| ** Learning** | | | |
20- | Structured Path | ` learning/curriculum.md ` (Planned) | N/A | ** Missing ** |
20+ | Structured Path | ` learning/curriculum.md ` | N/A | OK |
Original file line number Diff line number Diff line change 2323 - Includes prerequisites, tasks, and pitfalls for each module.
2424
2525## ✅ Verification
26- - Created temporary test ` crates/rustapi-rs/tests/doc_check_pagination.rs ` to verify the new recipe code compiles.
26+ - Locally created a temporary test in ` crates/rustapi-rs/tests/ ` to verify the new recipe code compiles (not committed to the repo) .
2727- Verified that ` rustapi-core ` compiles with the new Schema implementations.
2828
2929## 📝 TODOs for Next Run
Original file line number Diff line number Diff line change @@ -36,7 +36,7 @@ struct Pagination {
3636#[rustapi_rs:: get(" /users" )]
3737async fn list_users (Query (params ): Query <Pagination >) -> Json <ResourceCollection <User >> {
3838 let page = params . page. unwrap_or (0 );
39- let size = params . size. unwrap_or (20 );
39+ let size = params . size. unwrap_or (20 ). max ( 1 ); // Ensure size is at least 1 to prevent division by zero
4040
4141 // In a real app, you would fetch this from a database
4242 // let (users, total_elements) = db.fetch_users(page, size).await?;
You can’t perform that action at this time.
0 commit comments