@nestjs/platform-fastify 8.2.4 → 8.3.1

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.
package/LICENSE CHANGED
@@ -1,6 +1,6 @@
1
1
  (The MIT License)
2
2
 
3
- Copyright (c) 2017-2021 Kamil Mysliwiec <https://kamilmysliwiec.com>
3
+ Copyright (c) 2017-2022 Kamil Mysliwiec <https://kamilmysliwiec.com>
4
4
 
5
5
  Permission is hereby granted, free of charge, to any person obtaining
6
6
  a copy of this software and associated documentation files (the
package/Readme.md CHANGED
@@ -84,7 +84,8 @@ Nest is an MIT-licensed open source project. It can grow thanks to the sponsors
84
84
  <a href="https://www.myleodsc.com/" target="_blank"><img src="https://nestjs.com/img/myleo-logo.png" width="180" valign="middle" /></td><td>
85
85
  <a href="https://careers.meetdandy.com/?gh_src=063ba61e3us" target="_blank"><img src="https://nestjs.com/img/dandy-roles-logo.svg" width="150" valign="middle" /></td><td>
86
86
  <a href="https://www.castlecraft.in" target="_blank"><img src="https://nestjs.com/img/castlecraft-logo.png" width="150" valign="middle" /></td>
87
- <td><a href="https://www.tinystacks.com" target="_blank"><img src="https://nestjs.com/img/tinystacks-logo.png#1" width="140" valign="middle" /></td></tr></table>
87
+ <td><a href="https://www.tinystacks.com" target="_blank"><img src="https://nestjs.com/img/tinystacks-logo.png#1" width="140" valign="middle" /></td>
88
+ <td><a href="https://n.inc" target="_blank"><img src="https://nestjs.com/img/n-inc-logo.svg" width="120" valign="middle" /></td></tr></table>
88
89
 
89
90
  #### Sponsors
90
91
 
@@ -118,6 +119,11 @@ Nest is an MIT-licensed open source project. It can grow thanks to the sponsors
118
119
  <td align="center" valign="middle"><a href="https://www.naologic.com/" target="_blank"><img src="https://nestjs.com/img/naologic-logo.svg" width="125" valign="middle" /></a></td>
119
120
  <td align="center" valign="middle"><a href="https://messaged.com/" target="_blank"><img src="https://nestjs.com/img/messaged-logo.png" width="50" valign="middle" /></a></td>
120
121
  <td align="center" valign="middle"><a href="https://triplecore.io" target="_blank"><img src="https://nestjs.com/img/triplecore-logo.svg" width="50" valign="middle" /></a></td>
122
+ <td align="center" valign="middle"><a href="https://klqc.de" target="_blank"><img src="https://nestjs.com/img/klcqcl-logo.png" width="120" valign="middle" /></a></td>
123
+ <td align="center" valign="middle"><a href="https://thecasinowizard.com/bonuses/no-deposit-bonuses/" target="_blank"><img src="https://nestjs.com/img/casinowizard-logo.png" width="120" valign="middle" /></a></td></tr><tr>
124
+ <td align="center" valign="middle"><a href="https://polygon-software.ch/" target="_blank"><img src="https://nestjs.com/img/polygon-logo.svg" width="120" valign="middle" /></a></td>
125
+ <td align="center" valign="middle"><a href="https://mobilereality.pl/" target="_blank"><img src="https://nestjs.com/img/mobile-reality-logo.png" width="45" valign="middle" /></a></td>
126
+ <td align="center" valign="middle"><a href="https://boringowl.io/" target="_blank"><img src="https://nestjs.com/img/boringowl-logo.svg" width="120" valign="middle" /></a></td>
121
127
  </tr></table>
122
128
 
123
129
  ## Backers
@@ -224,9 +224,11 @@ class FastifyAdapter extends http_adapter_1.AbstractHttpAdapter {
224
224
  await this.registerMiddie();
225
225
  }
226
226
  return (path, callback) => {
227
- const normalizedPath = path.endsWith('/*')
227
+ let normalizedPath = path.endsWith('/*')
228
228
  ? `${path.slice(0, -1)}(.*)`
229
229
  : path;
230
+ // Fallback to "(.*)" to support plugins like GraphQL
231
+ normalizedPath = normalizedPath === '/(.*)' ? '(.*)' : normalizedPath;
230
232
  // The following type assertion is valid as we use import('middie') rather than require('middie')
231
233
  // ref https://github.com/fastify/middie/pull/55
232
234
  this.instance.use(normalizedPath, callback);
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@nestjs/platform-fastify",
3
- "version": "8.2.4",
3
+ "version": "8.3.1",
4
4
  "description": "Nest - modern, fast, powerful node.js web framework (@platform-fastify)",
5
5
  "author": "Kamil Mysliwiec",
6
6
  "license": "MIT",
@@ -17,11 +17,11 @@
17
17
  "access": "public"
18
18
  },
19
19
  "dependencies": {
20
- "fastify": "3.24.1",
20
+ "fastify": "3.27.1",
21
21
  "fastify-cors": "6.0.2",
22
22
  "fastify-formbody": "5.2.0",
23
- "light-my-request": "4.7.0",
24
- "middie": "5.3.0",
23
+ "light-my-request": "4.7.1",
24
+ "middie": "6.0.0",
25
25
  "path-to-regexp": "3.2.0",
26
26
  "tslib": "2.3.1"
27
27
  },