Huge News!Announcing our $40M Series B led by Abstract Ventures.Learn More
Socket
Sign inDemoInstall
Socket

@nestjs/config

Package Overview
Dependencies
Maintainers
2
Versions
56
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

@nestjs/config - npm Package Compare versions

Comparing version 1.1.5 to 1.1.6

2

dist/config.module.js

@@ -64,3 +64,3 @@ "use strict";

const validationOptions = this.getSchemaValidationOptions(options);
const { error, value: validatedConfig, } = options.validationSchema.validate(config, validationOptions);
const { error, value: validatedConfig } = options.validationSchema.validate(config, validationOptions);
if (error) {

@@ -67,0 +67,0 @@ throw new Error(`Config validation error: ${error.message}`);

@@ -14,5 +14,2 @@ "use strict";

};
var __importDefault = (this && this.__importDefault) || function (mod) {
return (mod && mod.__esModule) ? mod : { "default": mod };
};
Object.defineProperty(exports, "__esModule", { value: true });

@@ -22,5 +19,3 @@ exports.ConfigService = void 0;

const shared_utils_1 = require("@nestjs/common/utils/shared.utils");
const lodash_get_1 = __importDefault(require("lodash.get"));
const lodash_has_1 = __importDefault(require("lodash.has"));
const lodash_set_1 = __importDefault(require("lodash.set"));
const lodash_1 = require("lodash");
const config_constants_1 = require("./config.constants");

@@ -65,3 +60,3 @@ let ConfigService = class ConfigService {

getFromCache(propertyPath, defaultValue) {
const cachedValue = (0, lodash_get_1.default)(this.cache, propertyPath);
const cachedValue = (0, lodash_1.get)(this.cache, propertyPath);
return (0, shared_utils_1.isUndefined)(cachedValue)

@@ -72,3 +67,3 @@ ? defaultValue

getFromValidatedEnv(propertyPath) {
const validatedEnvValue = (0, lodash_get_1.default)(this.internalConfig[config_constants_1.VALIDATED_ENV_PROPNAME], propertyPath);
const validatedEnvValue = (0, lodash_1.get)(this.internalConfig[config_constants_1.VALIDATED_ENV_PROPNAME], propertyPath);
return validatedEnvValue;

@@ -78,7 +73,7 @@ }

if (this.isCacheEnabled &&
(0, lodash_has_1.default)(this.cache, propertyPath)) {
(0, lodash_1.has)(this.cache, propertyPath)) {
const cachedValue = this.getFromCache(propertyPath, defaultValue);
return !(0, shared_utils_1.isUndefined)(cachedValue) ? cachedValue : defaultValue;
}
const processValue = (0, lodash_get_1.default)(process.env, propertyPath);
const processValue = (0, lodash_1.get)(process.env, propertyPath);
this.setInCacheIfDefined(propertyPath, processValue);

@@ -88,3 +83,3 @@ return processValue;

getFromInternalConfig(propertyPath) {
const internalValue = (0, lodash_get_1.default)(this.internalConfig, propertyPath);
const internalValue = (0, lodash_1.get)(this.internalConfig, propertyPath);
return internalValue;

@@ -96,3 +91,3 @@ }

}
(0, lodash_set_1.default)(this.cache, propertyPath, value);
(0, lodash_1.set)(this.cache, propertyPath, value);
}

@@ -99,0 +94,0 @@ isGetOptionsObject(options) {

"use strict";
var __importDefault = (this && this.__importDefault) || function (mod) {
return (mod && mod.__esModule) ? mod : { "default": mod };
};
Object.defineProperty(exports, "__esModule", { value: true });
exports.mergeConfigObject = void 0;
const lodash_set_1 = __importDefault(require("lodash.set"));
const lodash_1 = require("lodash");
function mergeConfigObject(host, partial, token) {
if (token) {
(0, lodash_set_1.default)(host, token, partial);
(0, lodash_1.set)(host, token, partial);
return partial;

@@ -12,0 +9,0 @@ }

{
"name": "@nestjs/config",
"version": "1.1.5",
"version": "1.1.6",
"description": "Nest - modern, fast, powerful node.js web framework (@config)",

@@ -23,36 +23,32 @@ "author": "Kamil Mysliwiec",

"dotenv-expand": "5.1.0",
"lodash.get": "4.4.2",
"lodash.has": "4.5.2",
"lodash.set": "4.3.2",
"lodash": "4.17.21",
"uuid": "8.3.2"
},
"devDependencies": {
"@commitlint/cli": "15.0.0",
"@commitlint/config-angular": "15.0.0",
"@nestjs/common": "8.2.3",
"@nestjs/core": "8.2.3",
"@nestjs/platform-express": "8.2.3",
"@nestjs/testing": "8.2.3",
"@types/jest": "27.0.3",
"@types/lodash.get": "4.4.6",
"@types/lodash.has": "4.5.6",
"@types/lodash.set": "4.3.6",
"@types/node": "16.11.10",
"@commitlint/cli": "16.0.1",
"@commitlint/config-angular": "16.0.0",
"@nestjs/common": "8.2.4",
"@nestjs/core": "8.2.4",
"@nestjs/platform-express": "8.2.4",
"@nestjs/testing": "8.2.4",
"@types/jest": "27.4.0",
"@types/lodash": "4.14.178",
"@types/node": "16.11.17",
"@types/uuid": "8.3.3",
"@typescript-eslint/eslint-plugin": "5.4.0",
"@typescript-eslint/parser": "5.4.0",
"eslint": "8.3.0",
"@typescript-eslint/eslint-plugin": "5.8.1",
"@typescript-eslint/parser": "5.8.1",
"eslint": "8.6.0",
"eslint-config-prettier": "8.3.0",
"eslint-plugin-import": "2.25.3",
"eslint-plugin-import": "2.25.4",
"husky": "7.0.4",
"jest": "27.3.1",
"joi": "17.4.2",
"lint-staged": "12.1.2",
"prettier": "2.5.0",
"jest": "27.4.5",
"joi": "17.5.0",
"lint-staged": "12.1.5",
"prettier": "2.5.1",
"reflect-metadata": "0.1.13",
"release-it": "14.11.8",
"rimraf": "3.0.2",
"rxjs": "7.4.0",
"ts-jest": "27.0.7",
"typescript": "4.5.2"
"rxjs": "7.5.1",
"ts-jest": "27.1.2",
"typescript": "4.5.4"
},

@@ -59,0 +55,0 @@ "peerDependencies": {

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