Socket
Socket
Sign inDemoInstall

@silvermine/dynamodb-table-sync

Package Overview
Dependencies
20
Maintainers
3
Versions
7
Alerts
File Explorer

Advanced tools

Install Socket

Detect and block malicious and high-risk dependencies

Install

Comparing version 1.0.1 to 1.0.2

8

package.json
{
"name": "@silvermine/dynamodb-table-sync",
"version": "1.0.1",
"version": "1.0.2",
"description": "utility script for detecting and (optionally) fixing differences between multiple DynamoDB tables (in the same or different regions)",

@@ -41,10 +41,10 @@ "main": "src/Synchronizer.js",

"devDependencies": {
"coveralls": "2.13.1",
"coveralls": "3.0.2",
"eslint": "4.0.0",
"eslint-config-silvermine": "1.3.0",
"expect.js": "0.3.1",
"grunt": "1.0.1",
"grunt": "1.0.3",
"grunt-eslint": "20.0.0",
"istanbul": "0.4.5",
"mocha": "3.4.2",
"mocha": "5.2.0",
"mocha-lcov-reporter": "1.3.0",

@@ -51,0 +51,0 @@ "rewire": "2.5.2",

@@ -7,3 +7,4 @@ 'use strict';

Class = require('class.extend'),
Counter = require('./lib/Counter');
Counter = require('./lib/Counter'),
REPLICATION_FIELDS = [ 'aws:rep:updateregion', 'aws:rep:updatetime', 'aws:rep:deleting' ];

@@ -189,9 +190,4 @@ module.exports = Class.extend({

isItemDifferent: function(masterItem, slaveItem) {
var atts = this._opts.ignoreAtts;
var atts = _.union(this._opts.ignoreAtts, REPLICATION_FIELDS);
if (_.isEmpty(atts)) {
return !_.isEqual(masterItem, slaveItem);
}
return !_.isEqual(_.omit(masterItem, atts), _.omit(slaveItem, atts));

@@ -284,3 +280,3 @@ },

console.log('Writing item to %s: %j', tableDef.id, this._makeKeyFromItem(item));
return Q.ninvoke(tableDef.docs, 'put', { TableName: tableDef.name, Item: item });
return Q.ninvoke(tableDef.docs, 'put', { TableName: tableDef.name, Item: _.omit(item, REPLICATION_FIELDS) });
},

@@ -287,0 +283,0 @@

SocketSocket SOC 2 Logo

Product

  • Package Alerts
  • Integrations
  • Docs
  • Pricing
  • FAQ
  • Roadmap

Stay in touch

Get open source security insights delivered straight into your inbox.


  • Terms
  • Privacy
  • Security

Made with ⚡️ by Socket Inc