Comparing version 0.9.4-63 to 0.9.5-65
@@ -77,3 +77,9 @@ 'use strict'; | ||
var request = original.call(this, options, agent.tracer.callbackProxy(callback)); | ||
var request; | ||
if (callback) { | ||
request = original.call(this, options, agent.tracer.callbackProxy(callback)); | ||
} | ||
else { | ||
request = original.apply(this, arguments); | ||
} | ||
@@ -80,0 +86,0 @@ if (!internalOnly) { |
@@ -48,2 +48,5 @@ 'use strict'; | ||
Tracer.prototype.transactionProxy = function (handler) { | ||
// if there's no handler, there's nothing to proxy. | ||
if (!handler) return; | ||
var self = this; | ||
@@ -72,2 +75,5 @@ return function wrapTransactionInvocation() { | ||
Tracer.prototype.segmentProxy = function (handler) { | ||
// if there's no handler, there's nothing to proxy. | ||
if (!handler) return; | ||
var self = this; | ||
@@ -100,2 +106,5 @@ return function wrapSegmentInvocation() { | ||
Tracer.prototype.callbackProxy = function (handler) { | ||
// if there's no handler, there's nothing to proxy. | ||
if (!handler) return; | ||
// don't implicitly create transactions | ||
@@ -102,0 +111,0 @@ var state = this.context.state; |
@@ -211,2 +211,5 @@ 'use strict'; | ||
Tracer.prototype.transactionProxy = function (handler) { | ||
// if there's no handler, there's nothing to proxy. | ||
if (!handler) return; | ||
this.describer.traceWrapping('->', 'T outer'); | ||
@@ -255,2 +258,5 @@ | ||
Tracer.prototype.segmentProxy = function (handler) { | ||
// if there's no handler, there's nothing to proxy. | ||
if (!handler) return; | ||
this.describer.traceWrapping('->', 'S outer'); | ||
@@ -299,2 +305,5 @@ | ||
Tracer.prototype.callbackProxy = function (handler) { | ||
// if there's no handler, there's nothing to proxy. | ||
if (!handler) return; | ||
// don't implicitly create transactions | ||
@@ -301,0 +310,0 @@ var state = this.context.state; |
@@ -11,5 +11,5 @@ 'use strict'; | ||
function State(transaction, segment, call, debug) { | ||
if (!transaction) return new Error("State must be created with a transaction."); | ||
if (!segment) return new Error("State must be created with a trace segment."); | ||
if (!call) return new Error("State must be created with a handler function."); | ||
if (!transaction) throw new Error("State must be created with a transaction."); | ||
if (!segment) throw new Error("State must be created with a trace segment."); | ||
if (!call) throw new Error("State must be created with a handler function."); | ||
@@ -16,0 +16,0 @@ this.transaction = transaction; |
@@ -0,1 +1,5 @@ | ||
### v0.9.5-63 / beta-06 (2012-11-28): | ||
* Be more careful in dealing with HTTP requests. | ||
### v0.9.4-61 / beta-05 (2012-11-26): | ||
@@ -2,0 +6,0 @@ |
{ | ||
"name": "newrelic", | ||
"version": "0.9.4-63", | ||
"version": "0.9.5-65", | ||
"author": "New Relic Node.js agent team <nodejs@newrelic.com>", | ||
@@ -5,0 +5,0 @@ "contributors": [ |
@@ -59,3 +59,5 @@ 'use strict'; | ||
fs.exists(dbpath, function (exists) { | ||
var exist = fs.exists || path.exists; | ||
exist(dbpath, function (exists) { | ||
if (!exists) { | ||
@@ -62,0 +64,0 @@ fs.mkdir(dbpath, '0755', function (err) { |
Install scripts
Supply chain riskInstall scripts are run when the package is installed. The majority of malware in npm is hidden in install scripts.
Found 1 instance in 1 package
Network access
Supply chain riskThis module accesses the network.
Found 1 instance in 1 package
Dynamic require
Supply chain riskDynamic require can indicate the package is performing dangerous or unsafe dynamic code execution.
Found 1 instance in 1 package
Environment variable access
Supply chain riskPackage accesses environment variables, which may be a sign of credential stuffing or data theft.
Found 2 instances in 1 package
509800
175
11840
1
202
22