Open
Description
Problem
As the title suggestest i send a graphql request, i do this in 3 different situations but in one of those
the method SendQueryAsync just stops without any errors(tried try catch and breakpoints).
####Details
I have one Class to do this request, i use it mutliple times, but in one case it doesn't work and i have no idea
why, or how to debbug it.
There is nothing noticable in the Stacktrace aswell as far as im concerned
###This is my Code
using GermanFishing.Model.GraphQLImages;
using GraphQL.Client.Http;
using GraphQL.Client.Serializer.Newtonsoft;
using System;
using System.Collections.Generic;
using System.IO;
using System.Text;
using System.Threading.Tasks;
using Xamarin.Forms;
namespace GermanFishing.ViewModel
{
public class UserViewModel
{
public User user_profile { get; set; }
public UserViewModel()
{
user_profile = new User();
}
//Consume User Data from Graphql
public async Task GetProfileData()
{
var client = new GraphQLHttpClient(new GraphQLHttpClientOptions
{
EndPoint = new Uri("https://www.german-fishing.de/graphql"),
}, new NewtonsoftJsonSerializer());
client.HttpClient.DefaultRequestHeaders.Add("Authorization", "Bearer " + Convert.ToString(Application.Current.Properties["Login"]));
var request = new GraphQLHttpRequest
{
Query = @"
query {
me {
name
unreadNotifications {
data
}
abonnements {
id
place {
id
name
}
}
}
}"
};
var response = await client.SendQueryAsync<UserImage>(request).ConfigureAwait(false);
this.user_profile = response.Data.me;
}
}
}
Any suggestions how to approach this ?
Metadata
Metadata
Assignees
Labels
No labels