RefitXamarinFormsSample
RefitXamarinFormsSample copied to clipboard
Remove Running Tasks
In your ApiManager you build a Dictionary of tasks that you fill with the task ids before calling the RemoteRequestAsync methods. If this task executed successfully, you remove it from the Dictionary in ExecuteAsync. The thing is that the id does not correspond to the one that you added. For example:
- The task id of RemoteRequestAsync<HttpResponseMessage>(makeUpApi.GetApi(Priority.UserInitiated).GetMakeUps(brand, cts.Token))
- Is obviously not equal to the task id of makeUpApi.GetApi(Priority.UserInitiated).GetMakeUps(brand, cts.Token) that you pass as parameter.