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

pigretto

Package Overview
Dependencies
Maintainers
1
Versions
69
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

pigretto - npm Package Compare versions

Comparing version 2.4.1 to 2.4.2

3

dist/es6/trap/executors/CallTrapExecutor.js

@@ -28,2 +28,3 @@ /*

import { bindContextThisArg } from "../../polyfill/polyfill";
import { isEmpty } from "js-utl";
export default withFunctionTrapExecutor(class CallTrapExecutor extends TrapExecutor {

@@ -35,3 +36,3 @@ getTrapArgsArgumentsListIndex() {

execute([target, property, receiver, propertyValue], before, around, after) {
if (typeof propertyValue === "function") {
if (typeof propertyValue === "function" && [before, around, after].some(advices => !isEmpty(advices))) {
const superExecute = trapArgs => {

@@ -38,0 +39,0 @@ return super.execute(trapArgs, before, around, after);

{
"name": "pigretto",
"version": "2.4.1",
"version": "2.4.2",
"description": "A JS helper to easily implement proxies, facades, lazy loading and monkey patching using an API with an AOP flavor.",

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

@@ -29,2 +29,3 @@ /*

import { bindContextThisArg } from "../../polyfill/polyfill";
import { isEmpty } from "js-utl";

@@ -43,3 +44,6 @@ export default withFunctionTrapExecutor(

) {
if (typeof propertyValue === "function") {
if (
typeof propertyValue === "function" &&
[before, around, after].some(advices => !isEmpty(advices))
) {
const superExecute = trapArgs => {

@@ -46,0 +50,0 @@ return super.execute(trapArgs, before, around, after);

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 too big to display

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