@nxtedition/lib 19.5.1 → 19.5.2
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/deepstream.js +7 -2
- package/package.json +1 -1
package/deepstream.js
CHANGED
|
@@ -169,10 +169,15 @@ function query(ds, designId, params, state = ds.record.PROVIDER) {
|
|
|
169
169
|
if (finished) {
|
|
170
170
|
return rxjs.of({ rows: nextRows })
|
|
171
171
|
} else {
|
|
172
|
-
|
|
172
|
+
let nextKey = rows.pop().key
|
|
173
173
|
// assert(last.key)
|
|
174
174
|
// assert(rows.length > 0)
|
|
175
|
-
|
|
175
|
+
if (nextKey === startkey) {
|
|
176
|
+
// TODO (fix): We need to use startkey_docid to properly handle this...
|
|
177
|
+
// See, https://docs.couchdb.org/en/stable/ddocs/views/pagination.html#paging-alternate-method
|
|
178
|
+
nextKey += '\u0000'
|
|
179
|
+
}
|
|
180
|
+
return next(nextKey, nextRows, limit - rows.length)
|
|
176
181
|
}
|
|
177
182
|
}),
|
|
178
183
|
)
|