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

comdb

Package Overview
Dependencies
Maintainers
1
Versions
21
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

comdb - npm Package Compare versions

Comparing version 1.1.1-beta to 1.2.0-beta

6

index.js

@@ -73,4 +73,6 @@ 'use strict'

PouchDB.replicate = function (source, target, opts = {}, callback) {
if (source._encrypted) source = source._encrypted
if (target._encrypted) target = target._encrypted
if (opts.comdb !== false) {
if (source._encrypted) source = source._encrypted
if (target._encrypted) target = target._encrypted
}
const promise = replicate(source, target, opts)

@@ -77,0 +79,0 @@ return cbify(promise, callback)

{
"name": "comdb",
"version": "1.1.1-beta",
"version": "1.2.0-beta",
"description": "A PouchDB plugin that transparently encrypts and decrypts its data.",

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

@@ -117,2 +117,9 @@ # ComDB

You can also disable this functionality by passing `comdb: false` in the `opts`
parameter:
```javascript
PouchDB.replicate(db1, db2, { comdb: false })
```
The instance methods `db.replicate.to` and `db.replicate.from` automatically use `PouchDB.replicate` so that wrapping the static method causes the instance methods to exhibit the same behavior.

@@ -119,0 +126,0 @@

@@ -106,2 +106,17 @@ /* global describe, it, before, after */

})
it('should perform normal replication ok', async function () {
return this.db.replicate.to(this.db2, { comdb: false }).then(() => {
const opts = { include_docs: true }
return Promise.all([
this.db.allDocs(opts),
this.db2.allDocs(opts)
]).then(([results1, results2]) => {
assert.strictEqual(results1.total_rows, results2.total_rows)
const doc1 = results1.rows[0].doc
const doc2 = results2.rows[0].doc
assert(isEqual(doc1, doc2))
})
})
})
})

@@ -108,0 +123,0 @@

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