Socket
Socket
Sign inDemoInstall

viewmodel

Package Overview
Dependencies
Maintainers
2
Versions
109
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

viewmodel - npm Package Compare versions

Comparing version 1.7.5 to 1.7.6

26

lib/databases/dynamodb.js

@@ -306,4 +306,18 @@ 'use strict';

if(_.isPlainObject(valueSearchedFor)) {
result = _.merge(result, createDynamoParams(valueSearchedFor, dotNotatedTargetAttribute));
result.expressionAttributeNames['#' + key] = key;
result.expressionAttributeNames['#' + key] = key;
const newCondition = createDynamoParams(valueSearchedFor, dotNotatedTargetAttribute);
result.expressionAttributeNames = _.merge(
result.expressionAttributeNames,
newCondition.expressionAttributeNames);
result.expressionAttributeValues = _.merge(
result.expressionAttributeValues,
newCondition.expressionAttributeValues);
if (!_.isEmpty(newCondition.filterExpression)) {
result.filterExpression = result.filterExpression.concat(
_.isEmpty(result.filterExpression) ? '' : ' AND ',
newCondition.filterExpression);
}
} else {

@@ -314,6 +328,10 @@ var attributeVariable = ':' + dotNotatedTargetAttribute.replace(/(\.|#)/g, '');

if (result.filterExpression !== '') {
result.filterExpression = result.filterExpression + ' AND ';
result.filterExpression = result.filterExpression.concat(' AND ');
}
result.filterExpression = result.filterExpression + dotNotatedTargetAttribute + ' = ' + attributeVariable;
result.filterExpression = result.filterExpression.concat(
dotNotatedTargetAttribute,
' = ',
attributeVariable);
result.expressionAttributeValues[attributeVariable] = valueSearchedFor;

@@ -320,0 +338,0 @@ result.expressionAttributeNames['#' + key] = key;

2

package.json
{
"author": "adrai",
"name": "viewmodel",
"version": "1.7.5",
"version": "1.7.6",
"private": false,

@@ -6,0 +6,0 @@ "main": "index.js",

@@ -0,1 +1,4 @@

## [v1.7.6](https://github.com/adrai/node-viewmodel/compare/v1.7.5...v1.7.6)
- Dynamodb filter expression fix [#55](https://github.com/adrai/node-viewmodel/pull/56) thanks to [Glockenbeat](https://github.com/Glockenbeat)
## [v1.7.5](https://github.com/adrai/node-viewmodel/compare/v1.7.4...v1.7.5)

@@ -2,0 +5,0 @@ - Switching DynamoDB scan to FilterExpression [#55](https://github.com/adrai/node-viewmodel/pull/55) thanks to [Glockenbeat](https://github.com/Glockenbeat)

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