Skip to content

Commit

Permalink
fix(examples): Update Pagination example
Browse files Browse the repository at this point in the history
  • Loading branch information
GeekMasher committed Jan 10, 2025
1 parent a6218d1 commit ef8e6f2
Showing 1 changed file with 1 addition and 4 deletions.
5 changes: 1 addition & 4 deletions examples/pagination.rs
Original file line number Diff line number Diff line change
Expand Up @@ -24,12 +24,9 @@ async fn main() -> Result<()> {

let mut page = Projects::paginate(&connection).await?;

/// Get the first page of projects
// Get the first page of projects
let mut projects = page.next(&connection).await?;
assert_eq!(page.page(), 0);
for project in &projects {
println!("Project: {}", project.name);
}

projects = page.next(&connection).await?;
assert_eq!(projects.len(), 100);
Expand Down

0 comments on commit ef8e6f2

Please sign in to comment.