@eropple/nestjs-correlation-id
Advanced tools
Comparing version 1.0.0 to 1.0.1
@@ -10,3 +10,3 @@ "use strict"; | ||
const correlationHeader = req.header("x-correlation-id") || genFn(); | ||
req.headers["X-Correlation-Id"] = correlationHeader; | ||
req.headers["x-correlation-id"] = correlationHeader; | ||
res.set("X-Correlation-Id", correlationHeader); | ||
@@ -13,0 +13,0 @@ next(); |
{ | ||
"name": "@eropple/nestjs-correlation-id", | ||
"version": "1.0.0", | ||
"version": "1.0.1", | ||
"description": "Middleware for managing X-Correlation-Id headers in NestJS (or any other Express app).", | ||
@@ -20,3 +20,2 @@ "main": "dist", | ||
"@nestjs/common": ">=6.0.0", | ||
"@nestjs/swagger": ">=3.0.2", | ||
"rxjs": ">=6.4.0" | ||
@@ -23,0 +22,0 @@ }, |
@@ -10,3 +10,4 @@ import { Injectable, NestMiddleware } from '@nestjs/common'; | ||
const correlationHeader = req.header("x-correlation-id") || genFn(); | ||
req.headers["X-Correlation-Id"] = correlationHeader; | ||
// make sure this is lower-cased, otherwise downstream stuff will barf. | ||
req.headers["x-correlation-id"] = correlationHeader; | ||
res.set("X-Correlation-Id", correlationHeader); | ||
@@ -13,0 +14,0 @@ next(); |
Sorry, the diff of this file is not supported yet
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
78705
4
110