-
Notifications
You must be signed in to change notification settings - Fork 64
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Null value when using Map over subscription #82
Comments
I just ran some tests and it seems a bug indeed. If i run this code:
It will return:
but if i call the ".first" method before the .map like this:
Then the map methos no longer returns null and returns the right value:
|
When do u work with Stream this Null result is expected, i forget to pass my sample tomorrow =/ |
I know that null is expeted, but it aways return null when i run the following code:
output:
|
Any movement on this, still seems to be the case with version 4.0.0+4 |
I have this code that works on hasura_connect version 1.2.2+1:
return db.subscription(itensSubscriptionQuery).map((data) => data['data']['models'].map<Model>((t) => Model.toJson(t)).toList());
With the 2.0.0 update the subscription method became a Future, so a changed my code to something like this:
return (await db.subscription(itensSubscriptionQuery)).map((data) => data['data']['models'].map<Model>((t) => Model.toJson(t)).toList());
But the map method aways return a null value on data.
If i change to somethig like this, it returns the data, but i lost the stream:
(await db.subscription( "subscription MyQuery {users {email}} ", )).first
The text was updated successfully, but these errors were encountered: