aws-xray-sdk-koa2
Advanced tools
Comparing version 3.3.3 to 3.3.4
@@ -1,2 +0,2 @@ | ||
import * as AWSXRay from "aws-xray-sdk-core"; | ||
import * as AWSXRay from 'aws-xray-sdk-core'; | ||
@@ -11,2 +11,2 @@ declare global { | ||
export * from "./koa_mw"; | ||
export * from './koa_mw'; |
@@ -11,3 +11,3 @@ /** | ||
const AWSXRay = require("aws-xray-sdk-core"); | ||
const AWSXRay = require('aws-xray-sdk-core'); | ||
@@ -29,6 +29,7 @@ const mwUtils = AWSXRay.middleware; | ||
openSegment: function openSegment(defaultName) { | ||
if (!defaultName || typeof defaultName !== "string") | ||
if (!defaultName || typeof defaultName !== 'string') { | ||
throw new Error( | ||
"Default segment name was not supplied. Please provide a string." | ||
'Default segment name was not supplied. Please provide a string.' | ||
); | ||
} | ||
@@ -49,3 +50,3 @@ mwUtils.setDefaultName(defaultName); | ||
mwUtils.middlewareLog("Starting koa segment", ctx.url, segment); | ||
mwUtils.middlewareLog('Starting koa segment', ctx.url, segment); | ||
@@ -98,3 +99,3 @@ if (AWSXRay.isAutomaticMode()) { | ||
segment.close(err); | ||
const message = err ? "Closed koa segment with error" : "Closed koa segment successfully"; | ||
const message = err ? 'Closed koa segment with error' : 'Closed koa segment successfully'; | ||
mwUtils.middlewareLog(message, ctx.url, segment); | ||
@@ -101,0 +102,0 @@ if (err) { |
{ | ||
"name": "aws-xray-sdk-koa2", | ||
"version": "3.3.3", | ||
"version": "3.3.4", | ||
"description": "AWS X-Ray Middleware for koa (Javascript)", | ||
@@ -17,3 +17,3 @@ "author": "Amazon Web Services", | ||
"lint": "eslint .", | ||
"lint:fix": "eslint --fix ./src", | ||
"lint:fix": "eslint --fix .", | ||
"test": "mocha --recursive --exit ./test/ -R spec && tsd", | ||
@@ -26,3 +26,3 @@ "test-d": "tsd" | ||
"peerDependencies": { | ||
"aws-xray-sdk-core": "^3.3.3", | ||
"aws-xray-sdk-core": "^3.3.4", | ||
"koa": "^2.0.0" | ||
@@ -44,3 +44,3 @@ }, | ||
"repository": "https://github.com/aws/aws-xray-sdk-node/tree/sdk_contrib/koa", | ||
"gitHead": "ff228eeee2009711553cbcac5033d525206aba96" | ||
"gitHead": "c74bc4a3aa7aa349f2c3e970135664d689ba717b" | ||
} |
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
17861
102