electrode-hapi-compat
Advanced tools
Comparing version 1.3.1 to 1.3.2
@@ -0,1 +1,6 @@ | ||
## [v1.3.2] 01-10-2020 | ||
- Fix `_testSet` API edge case | ||
- Instead of failing eagerly, fail on registration for fastify-incompatible plugins | ||
## [v1.3.1] 01-02-2020 | ||
@@ -2,0 +7,0 @@ |
@@ -46,3 +46,3 @@ "use strict"; | ||
HAPI_MAJOR_VERSION = 17; | ||
} else if (HAPI_MAJOR_VERSION === 17) { | ||
} else if (hapiMajor() === 17) { | ||
HAPI_MAJOR_VERSION = 16; | ||
@@ -55,3 +55,3 @@ } | ||
HAPI_MAJOR_VERSION = 18; | ||
} else if (HAPI_MAJOR_VERSION === 18) { | ||
} else if (hapiMajor() === 18) { | ||
HAPI_MAJOR_VERSION = 17; | ||
@@ -77,3 +77,4 @@ } | ||
if (!registers.fastify) { | ||
throw new Error("Plugin is not compatible with fastify"); | ||
// Lazily fail if the user tries to register this plugin with fastify. | ||
return () => Promise.reject(new Error("Plugin is not compatible with fastify")); | ||
} | ||
@@ -80,0 +81,0 @@ // allow modifying of parent fastify instance |
{ | ||
"name": "electrode-hapi-compat", | ||
"version": "1.3.1", | ||
"version": "1.3.2", | ||
"description": "Electrode Hapi 16/17/18 utility", | ||
@@ -5,0 +5,0 @@ "main": "lib/util.js", |
New author
Supply chain riskA new npm collaborator published a version of the package for the first time. New collaborators are usually benign additions to a project, but do indicate a change to the security surface area of a package.
Found 1 instance in 1 package
6549
111
1