Skip to content

Instantly share code, notes, and snippets.

@manakuro
Created December 10, 2021 04:58
Show Gist options
  • Select an option

  • Save manakuro/5648f7a0322cda63fc20acea92d62036 to your computer and use it in GitHub Desktop.

Select an option

Save manakuro/5648f7a0322cda63fc20acea92d62036 to your computer and use it in GitHub Desktop.
type User interface {
Get(ctx context.Context, id *model.ID) (*model.User, error)
List(ctx context.Context, after *model.Cursor, first *int, before *model.Cursor, last *int) (*model.UserConnection, error)
}
...
func (u *user) List(ctx context.Context, after *model.Cursor, first *int, before *model.Cursor, last *int) (*model.UserConnection, error) {
return u.userRepository.List(ctx, after, first, before, last)
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment