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

pouchdb-replication

Package Overview
Dependencies
Maintainers
3
Versions
39
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

pouchdb-replication - npm Package Compare versions

Comparing version 6.0.6 to 6.0.7

14

lib/index.js

@@ -12,3 +12,2 @@ 'use strict';

var pouchdbErrors = require('pouchdb-errors');
var jsExtend = require('js-extend');

@@ -139,2 +138,6 @@ function isGenOne(rev) {

function hasConflicts(doc) {
return doc._conflicts && doc._conflicts.length > 0;
}
function fetchRevisionOneDocs(ids) {

@@ -145,3 +148,4 @@ // Optimization: fetch gen-1 docs and attachments in

keys: ids,
include_docs: true
include_docs: true,
conflicts: true
}).then(function (res) {

@@ -153,3 +157,3 @@ if (state.cancelled) {

if (row.deleted || !row.doc || !isGenOne(row.value.rev) ||
hasAttachments(row.doc)) {
hasAttachments(row.doc) || hasConflicts(row.doc)) {
// if any of these conditions apply, we need to fetch using get()

@@ -774,4 +778,4 @@ return;

var optsPush = opts.push ? jsExtend.extend({}, opts, opts.push) : opts;
var optsPull = opts.pull ? jsExtend.extend({}, opts, opts.pull) : opts;
var optsPush = opts.push ? pouchdbUtils.jsExtend({}, opts, opts.push) : opts;
var optsPull = opts.pull ? pouchdbUtils.jsExtend({}, opts, opts.pull) : opts;

@@ -778,0 +782,0 @@ this.push = replicate(src, target, optsPush);

{
"name": "pouchdb-replication",
"version": "6.0.6",
"version": "6.0.7",
"description": "PouchDB's replication and sync algorithm, as a plugin.",

@@ -17,9 +17,8 @@ "main": "./lib/index.js",

"inherits": "2.0.3",
"js-extend": "1.0.1",
"pouchdb-checkpointer": "6.0.6",
"pouchdb-errors": "6.0.6",
"pouchdb-generate-replication-id": "6.0.6",
"pouchdb-promise": "6.0.6",
"pouchdb-utils": "6.0.6"
"pouchdb-checkpointer": "6.0.7",
"pouchdb-errors": "6.0.7",
"pouchdb-generate-replication-id": "6.0.7",
"pouchdb-promise": "6.0.7",
"pouchdb-utils": "6.0.7"
}
}

@@ -128,2 +128,6 @@ import { clone, flatten } from 'pouchdb-utils';

function hasConflicts(doc) {
return doc._conflicts && doc._conflicts.length > 0;
}
function fetchRevisionOneDocs(ids) {

@@ -134,3 +138,4 @@ // Optimization: fetch gen-1 docs and attachments in

keys: ids,
include_docs: true
include_docs: true,
conflicts: true
}).then(function (res) {

@@ -142,3 +147,3 @@ if (state.cancelled) {

if (row.deleted || !row.doc || !isGenOne(row.value.rev) ||
hasAttachments(row.doc)) {
hasAttachments(row.doc) || hasConflicts(row.doc)) {
// if any of these conditions apply, we need to fetch using get()

@@ -145,0 +150,0 @@ return;

@@ -1,2 +0,2 @@

import { extend } from 'js-extend';
import { jsExtend as extend } from 'pouchdb-utils';
import Promise from 'pouchdb-promise';

@@ -3,0 +3,0 @@ import {

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