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

elysia

Package Overview
Dependencies
Maintainers
1
Versions
462
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

elysia - npm Package Compare versions

Comparing version 1.2.0-exp.49 to 1.2.0-exp.50

20

dist/cjs/adapter/web-standard/handler.js

@@ -114,2 +114,3 @@ "use strict";

controller.enqueue(
// @ts-expect-error this is a valid operation
Buffer.from(JSON.stringify(init.value))

@@ -119,6 +120,11 @@ );

controller.enqueue(
// @ts-expect-error this is a valid operation
Buffer.from(init.value.toString())
);
}
else controller.enqueue(Buffer.from(init.value.toString()));
else
controller.enqueue(
// @ts-expect-error this is a valid operation
Buffer.from(init.value.toString())
);
}

@@ -131,8 +137,16 @@ for await (const chunk of generator) {

controller.enqueue(
// @ts-expect-error this is a valid operation
Buffer.from(JSON.stringify(chunk))
);
} catch {
controller.enqueue(Buffer.from(chunk.toString()));
controller.enqueue(
// @ts-expect-error this is a valid operation
Buffer.from(chunk.toString())
);
}
else controller.enqueue(Buffer.from(chunk.toString()));
else
controller.enqueue(
// @ts-expect-error this is a valid operation
Buffer.from(chunk.toString())
);
await new Promise(

@@ -139,0 +153,0 @@ (resolve) => setTimeout(() => resolve(), 0)

20

dist/cjs/compose.js

@@ -398,3 +398,3 @@ "use strict";

} else {
fnLiteral += `if(c.qi!==-1){let url = '&' + c.url.slice(c.qi + 1)
fnLiteral += `if(c.qi!==-1){let url = '&' + decodeURIComponent(c.url.slice(c.qi + 1))
`;

@@ -422,4 +422,4 @@ let index = 0;

let temp
if(memory===-1)temp=decodeURIComponent(url.slice(start).replace(/\\+/g,' '))
else temp=decodeURIComponent(url.slice(start, memory).replace(/\\+/g,' '))
if(memory===-1)temp=decodeURIComponent(url.slice(start).replace(/\\+|%20/g,' '))
else temp=decodeURIComponent(url.slice(start, memory).replace(/\\+|%20/g,' '))
const charCode = temp.charCodeAt(0)

@@ -439,4 +439,4 @@ if(charCode !== 91 && charCode !== 123)

if(a${index}===undefined)a${index}=[]
if(memory===-1){a${index}.push(decodeURIComponent(url.slice(start)).replace(/\\+/g,' '))
break}else a${index}.push(decodeURIComponent(url.slice(start, memory)).replace(/\\+/g,' '))
if(memory===-1){a${index}.push(decodeURIComponent(url.slice(start)).replace(/\\+|%20/g,' '))
break}else a${index}.push(decodeURIComponent(url.slice(start, memory)).replace(/\\+|%20/g,' '))
memory=url.indexOf('&${key}=',memory)

@@ -448,8 +448,8 @@ if(memory===-1) break

memory=url.indexOf('&',start)
if(memory===-1)a${index}=decodeURIComponent(url.slice(start).replace(/\\+/g,' '))else a${index}=decodeURIComponent(url.slice(start,memory).replace(/\\+/g,' '))if(a${index}!==undefined)try{a${index}=JSON.parse(a${index})}catch{}}`;
if(memory===-1)a${index}=decodeURIComponent(url.slice(start).replace(/\\+|%20/g,' '))else a${index}=decodeURIComponent(url.slice(start,memory).replace(/\\+|%20/g,' '))if(a${index}!==undefined)try{a${index}=JSON.parse(a${index})}catch{}}`;
else {
fnLiteral += init2 + `if(memory!==-1){const start=memory+${key.length + 2}
memory=url.indexOf('&',start)
if(memory===-1)a${index}=decodeURIComponent(url.slice(start).replace(/\\+/g,' '))
else{a${index}=decodeURIComponent(url.slice(start,memory).replace(/\\+/g,' '))`;
if(memory===-1)a${index}=decodeURIComponent(url.slice(start).replace(/\\+|%20/g,' '))
else{a${index}=decodeURIComponent(url.slice(start,memory).replace(/\\+|%20/g,' '))`;
if (anyOf)

@@ -464,4 +464,4 @@ fnLiteral += `

let value
if(deepMemory===-1)value=decodeURIComponent(url.slice(start).replace(/\\+/g,' '))
else value=decodeURIComponent(url.slice(start, deepMemory).replace(/\\+/g,' '))
if(deepMemory===-1)value=decodeURIComponent(url.slice(start).replace(/\\+|%20/g,' '))
else value=decodeURIComponent(url.slice(start, deepMemory).replace(/\\+|%20/g,' '))
const vStart=value.charCodeAt(0)

@@ -468,0 +468,0 @@ const vEnd=value.charCodeAt(value.length - 1)

@@ -186,3 +186,4 @@ "use strict";

default: (/* @__PURE__ */ new Date()).toISOString()
})
}),
t.Number()
],

@@ -192,2 +193,8 @@ property

).Decode((value) => {
if (typeof value === "number") {
const date2 = new Date(value);
if (!import_value.Value.Check(schema, date2))
throw new import_error.ValidationError("property", schema, date2);
return date2;
}
if (value instanceof Date) return value;

@@ -218,3 +225,3 @@ const date = new Date(value);

if (typeof value === "string") return value === "true";
if (property && !import_value.Value.Check(schema, value))
if (value !== void 0 && !import_value.Value.Check(schema, value))
throw new import_error.ValidationError("property", schema, value);

@@ -221,0 +228,0 @@ return value;

@@ -299,5 +299,5 @@ import type { Elysia, AnyElysia } from '.';

[key in keyof SelectedMacro as MacroFn[key] extends (...v: any[]) => {
resolve: MaybeArray<(...v: any) => Record<keyof any, unknown>>;
} ? key : never]: ResolveResolutions<ReturnType<MacroFn[key]>['resolve']>;
} extends infer A extends Record<RecordKey, unknown> ? IsNever<A[keyof A]> extends false ? A[keyof A] : {} : {};
resolve: MaybeArray<(...v: any) => MaybePromise<Record<keyof any, unknown>>>;
} ? key : never]: ResolveResolutions<Awaited<ReturnType<MacroFn[key]>['resolve']>>;
} extends infer A extends Record<RecordKey, unknown> ? IsNever<A[keyof A]> extends false ? Awaited<A[keyof A]> : {} : {};
export type InlineHandler<Route extends RouteSchema = {}, Singleton extends SingletonBase = {

@@ -304,0 +304,0 @@ decorator: {};

@@ -174,3 +174,3 @@ "use strict";

return data.then((data2) => handleWSResponse(ws, data2));
if (Buffer.isBuffer(data)) return ws.send(data);
if (Buffer.isBuffer(data)) return ws.send(data.toString());
if (data === void 0) return;

@@ -177,0 +177,0 @@ const send = (datum) => {

@@ -299,5 +299,5 @@ import type { Elysia, AnyElysia } from '.';

[key in keyof SelectedMacro as MacroFn[key] extends (...v: any[]) => {
resolve: MaybeArray<(...v: any) => Record<keyof any, unknown>>;
} ? key : never]: ResolveResolutions<ReturnType<MacroFn[key]>['resolve']>;
} extends infer A extends Record<RecordKey, unknown> ? IsNever<A[keyof A]> extends false ? A[keyof A] : {} : {};
resolve: MaybeArray<(...v: any) => MaybePromise<Record<keyof any, unknown>>>;
} ? key : never]: ResolveResolutions<Awaited<ReturnType<MacroFn[key]>['resolve']>>;
} extends infer A extends Record<RecordKey, unknown> ? IsNever<A[keyof A]> extends false ? Awaited<A[keyof A]> : {} : {};
export type InlineHandler<Route extends RouteSchema = {}, Singleton extends SingletonBase = {

@@ -304,0 +304,0 @@ decorator: {};

{
"name": "elysia",
"description": "Ergonomic Framework for Human",
"version": "1.2.0-exp.49",
"version": "1.2.0-exp.50",
"author": {

@@ -6,0 +6,0 @@ "name": "saltyAom",

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is too big to display

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

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