Skip to content

Decent way to use parseRequest with checked responses? #304

@mgsloan

Description

@mgsloan

The docs for parseRequest indicate that its checkResponse won't do anything. I looked around for a function to add the same checkResponse as used by parseUrlThrow, but couldn't find one. I'm thinking it makes sense to:

  • Add setRequestCheckStatus (opposite of setRequestIgnoreStatus), which adds the same status check as parseUrlThrow. Use this function in the definition of parseUrlThrow.
  • Add parseRequestThrow, which also uses setRequestCheckStatus.

Thoughts?

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions