Huge News!Announcing our $40M Series B led by Abstract Ventures.Learn More
Socket
Sign inDemoInstall
Socket

@sveltejs/adapter-node

Package Overview
Dependencies
Maintainers
4
Versions
167
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

@sveltejs/adapter-node - npm Package Compare versions

Comparing version 2.1.1 to 3.0.0

22

files/handler.js

@@ -975,8 +975,12 @@ import 'SHIMS';

if (body_size_limit !== undefined && content_length > body_size_limit) {
const error = new SvelteKitError(
413,
'Payload Too Large',
`Content-length of ${content_length} exceeds limit of ${body_size_limit} bytes.`
);
let message = `Content-length of ${content_length} exceeds limit of ${body_size_limit} bytes.`;
if (body_size_limit === 0) {
// https://github.com/sveltejs/kit/pull/11589
// TODO this exists to aid migration — remove in a future version
message += ' To disable body size limits, specify Infinity rather than 0.';
}
const error = new SvelteKitError(413, 'Payload Too Large', message);
controller.error(error);

@@ -1138,4 +1142,10 @@ return;

const port_header = env('PORT_HEADER', '').toLowerCase();
const body_size_limit = parseInt(env('BODY_SIZE_LIMIT', '524288')) || undefined;
const body_size_limit = Number(env('BODY_SIZE_LIMIT', '524288'));
if (isNaN(body_size_limit)) {
throw new Error(
`Invalid BODY_SIZE_LIMIT: '${env('BODY_SIZE_LIMIT')}'. Please provide a numeric value.`
);
}
const dir = path.dirname(fileURLToPath(import.meta.url));

@@ -1142,0 +1152,0 @@

{
"name": "@sveltejs/adapter-node",
"version": "2.1.1",
"version": "3.0.0",
"description": "Adapter for SvelteKit apps that generates a standalone Node server",

@@ -35,3 +35,3 @@ "repository": {

"vitest": "^1.0.4",
"@sveltejs/kit": "^2.2.1"
"@sveltejs/kit": "^2.3.0"
},

@@ -38,0 +38,0 @@ "dependencies": {

SocketSocket SOC 2 Logo

Product

  • Package Alerts
  • Integrations
  • Docs
  • Pricing
  • FAQ
  • Roadmap
  • Changelog

Packages

npm

Stay in touch

Get open source security insights delivered straight into your inbox.


  • Terms
  • Privacy
  • Security

Made with ⚡️ by Socket Inc