Socket
Socket
Sign inDemoInstall

babel-helper-evaluate-path

Package Overview
Dependencies
0
Maintainers
7
Versions
79
Alerts
File Explorer

Advanced tools

Install Socket

Detect and block malicious and high-risk dependencies

Install

Comparing version 0.5.0-alpha.6889f45d to 0.5.0-alpha.7195fa98

32

lib/index.js

@@ -146,19 +146,21 @@ "use strict";

const declaration = binding.path.parentPath;
/**
* Handle when binding is created inside a parent block and
* the corresponding parent is removed by other plugins
* if (false) { var a } -> var a
*/
if (declaration.parentPath && declaration.parentPath.removed) {
return {
confident: true,
value: void 0
};
}
if (declaration.parentPath) {
/**
* Handle when binding is created inside a parent block and
* the corresponding parent is removed by other plugins
* if (false) { var a } -> var a
*/
if (declaration.parentPath.removed) {
return {
confident: true,
value: void 0
};
}
if (declaration.parentPath.isIfStatement() || declaration.parentPath.isLoop() || declaration.parentPath.isSwitchCase()) {
return {
shouldDeopt: true
};
if (declaration.parentPath.isIfStatement() || declaration.parentPath.isLoop() || declaration.parentPath.isSwitchCase()) {
return {
shouldDeopt: true
};
}
}

@@ -165,0 +167,0 @@

{
"name": "babel-helper-evaluate-path",
"version": "0.5.0-alpha.6889f45d",
"version": "0.5.0-alpha.7195fa98",
"description": "path.evaluate wrapped in a try catch",

@@ -5,0 +5,0 @@ "keywords": [

SocketSocket SOC 2 Logo

Product

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

Stay in touch

Get open source security insights delivered straight into your inbox.


  • Terms
  • Privacy
  • Security

Made with ⚡️ by Socket Inc