fastify-static
Advanced tools
Comparing version 4.2.2 to 4.2.3
11
index.js
@@ -190,2 +190,13 @@ 'use strict' | ||
} | ||
// The `send` library terminates the request with a 404 if the requested | ||
// path contains a dotfile and `send` is initialized with `{dotfiles: | ||
// 'ignore'}`. `send` aborts the request before getting far enough to | ||
// check if the file exists (hence, a 404 `NotFoundError` instead of | ||
// `ENOENT`). | ||
// https://github.com/pillarjs/send/blob/de073ed3237ade9ff71c61673a34474b30e5d45b/index.js#L582 | ||
if (err.status === 404) { | ||
return reply.callNotFound() | ||
} | ||
reply.send(err) | ||
@@ -192,0 +203,0 @@ }) |
{ | ||
"name": "fastify-static", | ||
"version": "4.2.2", | ||
"version": "4.2.3", | ||
"description": "Plugin for serving static files as fast as possible.", | ||
@@ -40,3 +40,3 @@ "main": "index.js", | ||
"devDependencies": { | ||
"@types/node": "^15.0.0", | ||
"@types/node": "^16.0.0", | ||
"@typescript-eslint/eslint-plugin": "^2.29.0", | ||
@@ -56,3 +56,3 @@ "@typescript-eslint/parser": "^2.29.0", | ||
"tap": "^15.0.0", | ||
"tsd": "^0.15.0", | ||
"tsd": "^0.17.0", | ||
"typescript": "^4.0.2" | ||
@@ -59,0 +59,0 @@ }, |
@@ -100,3 +100,3 @@ # fastify-static | ||
### `prefixAvoidTrailingSlash` | ||
#### `prefixAvoidTrailingSlash` | ||
@@ -103,0 +103,0 @@ Default: `false` |
Sorry, the diff of this file is not supported yet
Sorry, the diff of this file is too big to display
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
334669
46
3920