Skip to content

REST - Does not handle the situation where response JSON has no root element. #30

Description

@delfindevassy13

public string GetStringFromBody(string xpath)

Does not handle the situation where response JSON has no root element.

Proposed solution is

doc= JsonConvert.DeserializeXmlNode(jsonOutput, "root");

Instead of

doc = JsonConvert.DeserializeXmlNode(response.Content);

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