vscode-jsonrpc
Advanced tools
Comparing version 2.1.0 to 2.1.1
@@ -190,2 +190,5 @@ /* -------------------------------------------------------------------------------------------- | ||
try { | ||
if (trace != Trace.Off && tracer) { | ||
traceReceivedNotification(message); | ||
} | ||
eventHandler(message.params); | ||
@@ -225,3 +228,3 @@ } | ||
} | ||
function traceNotification(message) { | ||
function traceSendNotification(message) { | ||
tracer.log("[" + (new Date().toLocaleTimeString()) + "] Sending notification '" + message.method + "'."); | ||
@@ -237,2 +240,13 @@ if (trace === Trace.Verbose) { | ||
} | ||
function traceReceivedNotification(message) { | ||
tracer.log("[" + (new Date().toLocaleTimeString()) + "] Received notification '" + message.method + "'."); | ||
if (trace === Trace.Verbose) { | ||
if (message.params) { | ||
tracer.log("Params: " + JSON.stringify(message.params, null, 4) + "\n\n"); | ||
} | ||
else { | ||
tracer.log('No parameters provided.\n\n'); | ||
} | ||
} | ||
} | ||
function traceResponse(message, responsePromise) { | ||
@@ -282,3 +296,3 @@ if (responsePromise) { | ||
if (trace != Trace.Off && tracer) { | ||
traceNotification(notificatioMessage); | ||
traceSendNotification(notificatioMessage); | ||
} | ||
@@ -285,0 +299,0 @@ messageWriter.write(notificatioMessage); |
{ | ||
"name": "vscode-jsonrpc", | ||
"description": "A json rpc implementation over streams", | ||
"version": "2.1.0", | ||
"version": "2.1.1", | ||
"author": "Microsoft Corporation", | ||
@@ -6,0 +6,0 @@ "license": "MIT", |
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
49702
1195