Skip to content

Instantly share code, notes, and snippets.

@manakuro
Created December 10, 2021 04:59
Show Gist options
  • Save manakuro/651eaa749c76603c9bde88a018b022a6 to your computer and use it in GitHub Desktop.
Save manakuro/651eaa749c76603c9bde88a018b022a6 to your computer and use it in GitHub Desktop.
func (r *userRepository) List(ctx context.Context, after *model.Cursor, first *int, before *model.Cursor, last *int) (*model.UserConnection, error) {
us, err := r.client.User.Query().Paginate(ctx, after, first, before, last)
if err != nil {
return nil, err
}
return us, nil
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment