Skip to content
This repository was archived by the owner on Sep 30, 2023. It is now read-only.

Commit 17cc191

Browse files
mistakiaaphelionz
authored andcommitted
fix: typo with lt param of iterator
1 parent e18a652 commit 17cc191

File tree

4 files changed

+10
-7
lines changed

4 files changed

+10
-7
lines changed

dist/ipfslog.min.js

Lines changed: 3 additions & 3 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

lib/es5/entry.js

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -31,6 +31,11 @@ var getWriteFormatForVersion = function getWriteFormatForVersion(v) {
3131
var getWriteFormat = function getWriteFormat(e) {
3232
return Entry.isEntry(e) ? getWriteFormatForVersion(e.v) : getWriteFormatForVersion(e);
3333
};
34+
/*
35+
* @description
36+
* An ipfs-log entry
37+
*/
38+
3439

3540
var Entry = /*#__PURE__*/function () {
3641
function Entry() {

lib/es5/log.js

Lines changed: 1 addition & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -72,8 +72,6 @@ var uniqueEntriesReducer = function uniqueEntriesReducer(res, acc) {
7272
return res;
7373
};
7474
/**
75-
* Log.
76-
*
7775
* @description
7876
* Log implements a G-Set CRDT and adds ordering.
7977
*
@@ -445,7 +443,7 @@ var Log = /*#__PURE__*/function (_GSet) {
445443
}, _callee2);
446444
})();
447445
if (typeof lte === 'string') lte = [this.get(lte)];
448-
if (typeof lt === 'string') lt = [this.get(this.get(lt).next)];
446+
if (typeof lt === 'string') lt = [this.get(this.get(lt).next[0])];
449447
if (lte && !Array.isArray(lte)) throw LogError.LtOrLteMustBeStringOrArray();
450448
if (lt && !Array.isArray(lt)) throw LogError.LtOrLteMustBeStringOrArray();
451449
var start = (lte || lt || this.heads).filter(isDefined);

src/log.js

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -349,7 +349,7 @@ class Log extends GSet {
349349
{}) {
350350
if (amount === 0) return (function * () {})()
351351
if (typeof lte === 'string') lte = [this.get(lte)]
352-
if (typeof lt === 'string') lt = [this.get(this.get(lt).next)]
352+
if (typeof lt === 'string') lt = [this.get(this.get(lt).next[0])]
353353

354354
if (lte && !Array.isArray(lte)) throw LogError.LtOrLteMustBeStringOrArray()
355355
if (lt && !Array.isArray(lt)) throw LogError.LtOrLteMustBeStringOrArray()

0 commit comments

Comments
 (0)