Skip to content

Commit 2ce5204

Browse files
committed
Another fix for ExecuteAsync
1 parent 196fa7e commit 2ce5204

File tree

1 file changed

+2
-2
lines changed

1 file changed

+2
-2
lines changed

RestSharp/RestClient.Async.cs

+2-2
Original file line numberDiff line numberDiff line change
@@ -53,7 +53,7 @@ public virtual RestRequestAsyncHandle ExecuteAsync(IRestRequest request, Action<
5353
/// <param name="httpMethod">The HTTP method to execute</param>
5454
public virtual RestRequestAsyncHandle ExecuteAsyncGet(IRestRequest request, Action<IRestResponse, RestRequestAsyncHandle> callback, string httpMethod)
5555
{
56-
return ExecuteAsync(request, callback, httpMethod, DoAsPostAsync);
56+
return ExecuteAsync(request, callback, httpMethod, DoAsGetAsync);
5757
}
5858

5959
/// <summary>
@@ -65,7 +65,7 @@ public virtual RestRequestAsyncHandle ExecuteAsyncGet(IRestRequest request, Acti
6565
public virtual RestRequestAsyncHandle ExecuteAsyncPost(IRestRequest request, Action<IRestResponse, RestRequestAsyncHandle> callback, string httpMethod)
6666
{
6767
request.Method = Method.POST; // Required by RestClient.BuildUri...
68-
return ExecuteAsync(request, callback, httpMethod, DoAsGetAsync);
68+
return ExecuteAsync(request, callback, httpMethod, DoAsPostAsync);
6969
}
7070

7171
private RestRequestAsyncHandle ExecuteAsync(IRestRequest request, Action<IRestResponse, RestRequestAsyncHandle> callback, string httpMethod, Func<IHttp, Action<HttpResponse>, string, HttpWebRequest> getWebRequest)

0 commit comments

Comments
 (0)