Skip to content

Conversation

Elywejnak
Copy link
Contributor

Hi, method RestClientExtensions.ExecuteDynamic throws InvalidCastException : Unable to cast object of type 'RestSharp.RestResponse' to type 'RestSharp.RestResponse`1[System.Object]'.
on line

var generic = (RestResponse<dynamic>)response;

Using generic Execute method repairs problem

var response = client.Execute<dynamic>(request);

this PR closes #536

hallem added a commit that referenced this pull request Oct 18, 2014
Repairs InvalidCastException on method RestClientExtensions.ExecuteDynamic
@hallem hallem merged commit cdbe353 into restsharp:master Oct 18, 2014
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

Extension method RestClientExtensions.ExecuteDynamic throws InvalidCastException 

2 participants