Socket
Socket
Sign inDemoInstall

rename-function

Package Overview
Dependencies
Maintainers
1
Versions
8
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

rename-function - npm Package Compare versions

Comparing version 1.0.4 to 1.0.5

5

CHANGELOG.md
## 1.0.5 - 2016-04-15
- Release v1.0.5 / npm@v1.0.5
- add test to ensure the fix for #2
- fix #2, always create new function and return it
## 1.0.4 - 2016-04-14

@@ -4,0 +9,0 @@ - Release v1.0.4 / npm@v1.0.4

4

index.js

@@ -57,6 +57,2 @@ /*!

if (fnName === name && !utils.isExtendable(ctx)) {
return fn
}
var str = format('return function %s() { return fn.apply(ctx || this, arguments) }', name)

@@ -63,0 +59,0 @@ var func = (new Function('fn', 'ctx', str))(fn, ctx || this) // eslint-disable-line no-new-func

{
"name": "rename-function",
"version": "1.0.4",
"version": "1.0.5",
"description": "Rename a given function. Tries to be cross-platform and guaranteed. Useful when you want to preserve name of bound function. In bonus, allows passing context to the renamed function.",

@@ -5,0 +5,0 @@ "repository": "tunnckoCore/rename-function",

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