Releases: ibm-garage/node-garage-utils
Releases · ibm-garage/node-garage-utils
6.0.1
6.0.0
⚠ BREAKING CHANGES
- cfutil: The cfutil CLI has been removed from this package. The code has been preserved in https://github.com/ibm-garage/node-garage-tools, with the intent that it could be published as a separate package if there is a need for it.
- time: The time API, which was deprecated in version 5.3.0, has now been removed entirely. Clients can declare a dependency directly on Moment.js. If required, they can also copy code from the removed time.js implementation.
- errors: Minor change to ResponseError: detail, code, and cause properties are always present, even if null or undefined.
- The minimum supported version of Node.js is now 12.13.0 (LTS Erbium).
Features
Bug Fixes
5.3.0
5.2.0
5.1.0
Features
- errors: expose a custom ResponseError class and do an instanceof check in toResponseError() (0300377)
Note: This is a minor behavior change, in that if you directly create an Error and set a status on it, it will no longer be treated like a proper response error created by responseError(). However, such usage was not anticipated and is not believed to exist, and this change protects against incorrectly treating an arbitrary error that happens to have a status property as an intended HTTP response.
5.0.2
5.0.1
No functional changes. Dependency updates.
5.0.0
This is a major release that reworks the errors API, removes the deprecated cf API, and drops support for obsolete Node.js releases.
⚠ BREAKING CHANGES
- The cf API, which was deprecated in version 4.1.0, has now been removed entirely. Clients should adopt the new cloudEnv API, which works in both Cloud Foundry and Kubernetes environments, or use the cfenv package directly.
- The minimum supported version of Node.js is now 10.13.0 (LTS Dubnium).
- errors: the errors API is completely changed. All clients using it must be updated accordingly.
- errors.error() is replaced by errors.responseError(), which no longer takes detail and cause separately as arguments, but together in an options argument.
- All the error factory functions (badRequest(), unauthorized(), etc.) now take a single, standard options argument, instead of varying arguments per function.
- responseBody() is replaced by toResponseBody(), which has a new options argument.
Features
- errors: introduce a more flexible API to support deatils, codes, and causes on all errors (2465aa2)