@gasket/plugin-fastify 6.47.0 → 6.47.5

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
@@ -44,6 +44,7 @@ module.exports = async function createServers(gasket, serverOpts) {
44
44
  }
45
45
 
46
46
  const middlewares = [];
47
+
47
48
  await gasket.execApply('middleware', async (plugin, handler) => {
48
49
  const middleware = await handler(app);
49
50
  if (middleware) {
package/lib/index.d.ts CHANGED
@@ -1,6 +1,6 @@
1
1
  import type { MaybeAsync, MaybeMultiple } from '@gasket/engine';
2
2
  import type {
3
- FastifyInstance,
3
+ Fastify,
4
4
  FastifyRequest,
5
5
  FastifyReply,
6
6
  FastifyServerOptions
@@ -31,11 +31,7 @@ declare module '@gasket/engine' {
31
31
  * Handler function type - The middie middleware is added for express
32
32
  * compatibility
33
33
  */
34
- type Handler = (
35
- req: FastifyRequest,
36
- res: FastifyReply,
37
- next: (error?: Error) => void
38
- ) => void;
34
+ type Handler = (req: any, res: any, next: (error?: Error) => void) => void;
39
35
 
40
36
  /** Error handler function type */
41
37
  type ErrorHandler = (
@@ -47,9 +43,9 @@ declare module '@gasket/engine' {
47
43
 
48
44
  export interface HookExecTypes {
49
45
  middleware(
50
- fastify: FastifyInstance
46
+ fastify: Fastify
51
47
  ): MaybeAsync<MaybeMultiple<Handler> & { paths?: (string | RegExp)[] }>;
52
- fastify(fastify: FastifyInstance): MaybeAsync<void>;
48
+ fastify(fastify: Fastify): MaybeAsync<void>;
53
49
  errorMiddleware(): MaybeAsync<MaybeMultiple<ErrorHandler>>;
54
50
  }
55
51
  }
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@gasket/plugin-fastify",
3
- "version": "6.47.0",
3
+ "version": "6.47.5",
4
4
  "description": "Adds fastify support to your application",
5
5
  "main": "lib",
6
6
  "types": "lib/index.d.ts",
@@ -45,7 +45,7 @@
45
45
  "middie": "^5.4.0"
46
46
  },
47
47
  "devDependencies": {
48
- "@gasket/engine": "^6.46.8",
48
+ "@gasket/engine": "^6.47.5",
49
49
  "cross-env": "^7.0.3",
50
50
  "eslint": "^8.56.0",
51
51
  "eslint-config-godaddy": "^7.1.0",
@@ -76,5 +76,5 @@
76
76
  "eslintIgnore": [
77
77
  "generator"
78
78
  ],
79
- "gitHead": "9feff1fa92be6b1b6ed2ab6d3028490165395c62"
79
+ "gitHead": "648355649de721c840c86f3456528617d44aba74"
80
80
  }