v0.7.0

@SaltwaterC SaltwaterC released this Oct 16, 2014

  • [MAY BREAK COMPAT] The Error objects thrown on wrong argument types were changed to TypeError. Standardised message output for these errors.
  • Fixed the client crash when noRedirect is used with a response that doesn't redirect.
  • Migrated from jslint to jshint.
  • Removed the warning about the deprecated options.bufferType.

v0.6.3

@SaltwaterC SaltwaterC released this Jun 11, 2014 · 9 commits to master since this release

  • New option: auth. Defines the HTTP Authentication parameters. Currently it only supports Basic authentication.

v0.6.2

@SaltwaterC SaltwaterC released this Feb 12, 2014 · 13 commits to master since this release

  • Closes #24. Keeps the host header specified into the request headers when the location header contains a relative path.
  • Adds some debugging info to the noRedirect option, the redirect-to-url and redirect-to-host as response headers. Related to the #24 issue.

v0.6.1

@SaltwaterC SaltwaterC released this Dec 5, 2013 · 16 commits to master since this release

  • Fixed the typo in content-length for Buffer reqBody.

New beginning

@SaltwaterC SaltwaterC released this Nov 6, 2013 · 20 commits to master since this release

v0.6.0

  • Client rewritten almost from scratch for including broader HTTP support. Renamed to http-request to indicate this change. New HTTP method wrappers: DELETE, POST, PUT.
  • Strict about user errors. They are considered unrecoverable aka won't fix without changing the code, hence they throw. Passing these to the completion callback has only one outcome: to conceal bugs.
  • Removed the support for HTTPS proxies since there's no way to do it properly, unless you actually control the proxy, which opens a door for MITM attacks.
  • The progress callback option is now available for all response handlers (file, buffer, stream).
  • Fix: the 201, 202, 203, 205 responses are handled as success (as they should).
  • Fix: the 305 responses are not handled as simple redirects. The library uses the location header information as options.proxy.
  • The 300 Multiple Choices responses are handled as errors instead of redirects. The location header, by RFC, indicates a preference, not something that must be automatically followed. It is up to the developer by using the response body (entity) to pick what to do next, or use the location header in a subsequent request.
  • Added a new option: noRedirect. Returns the headers and body (if applicable), for redirect requests.
  • Documentation generated with JSDoc 3.