Latest Threat Research:SANDWORM_MODE: Shai-Hulud-Style npm Worm Hijacks CI Workflows and Poisons AI Toolchains.Details
Socket
Book a DemoInstallSign in
Socket

@babel/helper-wrap-function

Package Overview
Dependencies
Maintainers
4
Versions
101
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

@babel/helper-wrap-function - npm Package Compare versions

Comparing version
8.0.0-beta.1
to
8.0.0-beta.2
+3
-3
lib/index.js

@@ -46,4 +46,4 @@ import template from '@babel/template';

let params = [];
const shoudlForwardParams = node.params.some(p => isPattern(p));
if (shoudlForwardParams) {
const shouldForwardParams = node.params.some(p => isPattern(p));
if (shouldForwardParams) {
params = node.params;

@@ -61,3 +61,3 @@ node.params = [];

const container = functionExpression(null, params, blockStatement(body.body), true);
if (shoudlForwardParams) {
if (shouldForwardParams) {
body.body = [returnStatement(callExpression(memberExpression(callExpression(callId, [container]), identifier("apply")), [thisExpression(), identifier("arguments")]))];

@@ -64,0 +64,0 @@ path.get("body.body.0.argument.callee.object.arguments.0").unwrapFunctionEnvironment();

{
"name": "@babel/helper-wrap-function",
"version": "8.0.0-beta.1",
"version": "8.0.0-beta.2",
"description": "Helper to wrap functions inside a function call.",

@@ -17,5 +17,5 @@ "repository": {

"dependencies": {
"@babel/template": "^8.0.0-beta.1",
"@babel/traverse": "^8.0.0-beta.1",
"@babel/types": "^8.0.0-beta.1"
"@babel/template": "^8.0.0-beta.2",
"@babel/traverse": "^8.0.0-beta.2",
"@babel/types": "^8.0.0-beta.2"
},

@@ -22,0 +22,0 @@ "engines": {

Sorry, the diff of this file is not supported yet