You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
funcGetTodoUsers(ctx context.Context, todoIDstring) ([]User, error) {
loaders:=For(ctx)
// I can't use .Load() because it returns T not []Treturnloaders.TodoLoader.LoadAll(ctx, []string{productID})
}
But when todoUsers() returns the users slice []User with len > 1 there is always an error:
"message": "bug in loader: 2 values returned for 1 keys"
Yes, it next case question.
How can I use "many to one" case for now?
For example, I have a single entity query with loader.Load(): ID --> []T{T, T, T}
Field resolver gets one entity "id"
For example we have:
In regular case I need a loader like this:
Function for gqlgen resolver
But when todoUsers() returns the users slice []User with len > 1 there is always an error:
How can I get in result something like this?
The text was updated successfully, but these errors were encountered: