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

penseur

Package Overview
Dependencies
Maintainers
1
Versions
103
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

penseur - npm Package Compare versions

Comparing version 6.4.0 to 6.5.0

6

lib/db.js

@@ -510,2 +510,7 @@ 'use strict';

}
static override(value) {
return internals.special('override', value);
}
};

@@ -520,2 +525,3 @@

internals.Db.prototype.append = internals.Db.append;
internals.Db.prototype.override = internals.Db.override;

@@ -522,0 +528,0 @@

@@ -49,2 +49,7 @@ 'use strict';

if (changes.type === 'override') {
without.push(internals.select(path));
return internals.wrap(changes.value, without, item, path);
}
let row = item(path[0]);

@@ -51,0 +56,0 @@ for (let i = 1; i < path.length; ++i) {

2

package.json
{
"name": "penseur",
"description": "Lightweight RethinkDB wrapper",
"version": "6.4.0",
"version": "6.5.0",
"author": "Eran Hammer <eran@hammer.io> (http://hueniverse.com)",

@@ -6,0 +6,0 @@ "repository": "git://github.com/hueniverse/penseur",

@@ -159,7 +159,5 @@ 'use strict';

let e = 0;
const onError = (err) => {
expect(err).to.exist();
++e;
db.connect = orig;

@@ -166,0 +164,0 @@ };

@@ -1109,2 +1109,35 @@ 'use strict';

});
it('updates a record (override key)', (done) => {
const db = new Penseur.Db('penseurtest');
db.establish(['test'], (err) => {
expect(err).to.not.exist();
db.test.insert({ id: 1, a: 1, b: { c: 1, d: 1 }, e: 1 }, (err, keys) => {
expect(err).to.not.exist();
db.test.update(1, { a: 2, b: { d: 2 } }, (err) => {
expect(err).to.not.exist();
db.test.get(1, (err, item1) => {
expect(err).to.not.exist();
expect(item1).to.equal({ id: 1, a: 2, b: { c: 1, d: 2 }, e: 1 });
db.test.update(1, { a: 3, b: db.override({ c: 2 }) }, (err) => {
expect(err).to.not.exist();
db.test.get(1, (err, item2) => {
expect(err).to.not.exist();
expect(item2).to.equal({ id: 1, a: 3, b: { c: 2 }, e: 1 });
done();
});
});
});
});
});
});
});
});

@@ -1111,0 +1144,0 @@

Sorry, the diff of this file is not supported yet

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