From 449b972e6aaed8cab60925f60c8dd69d0e367f21 Mon Sep 17 00:00:00 2001 From: Richard Hansen Date: Wed, 16 Feb 2022 22:29:42 -0500 Subject: [PATCH] Pad: Use default parameter value --- src/node/db/Pad.js | 4 +--- 1 file changed, 1 insertion(+), 3 deletions(-) diff --git a/src/node/db/Pad.js b/src/node/db/Pad.js index 7904b4e14..47c1f5d71 100644 --- a/src/node/db/Pad.js +++ b/src/node/db/Pad.js @@ -77,9 +77,7 @@ Pad.prototype.getPublicStatus = function () { return this.publicStatus; }; -Pad.prototype.appendRevision = async function (aChangeset, authorId) { - if (!authorId) authorId = ''; - +Pad.prototype.appendRevision = async function (aChangeset, authorId = '') { const newAText = Changeset.applyToAText(aChangeset, this.atext, this.pool); if (newAText.text === this.atext.text && newAText.attribs === this.atext.attribs) { return this.head;