Skip to content

CSharp RestSharp snippets don't generate valid members of RestSharp.Method enum #365

Description

@michaelgwelch

Here's a portion of the code generated from a csharp RestSharp code snippet

varrequest=newRestRequest(Method.GET);

The issue is that the actual member we need is Method.Get as shown in the source code here:

https://github.com/restsharp/RestSharp/blob/0fba5e727d241b1867bd71efc912594075c2934b/src/RestSharp/Enum.cs#L70

None of the Http Verbs are upper-cased in the enum definition.

Seems like I relatively easy fix. I'll try to write a PR.

Activity

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions