From c6adab7f9ec44b637cf3e80dcd1dbff716506efd Mon Sep 17 00:00:00 2001 From: hacksalot Date: Wed, 31 Jan 2018 00:10:37 -0500 Subject: [PATCH] [fix] Private fields: Resolve off-by-one error. --- dist/core/abstract-resume.js | 4 ++-- src/core/abstract-resume.coffee | 5 +++-- 2 files changed, 5 insertions(+), 4 deletions(-) diff --git a/dist/core/abstract-resume.js b/dist/core/abstract-resume.js index 343ca78..cca2655 100644 --- a/dist/core/abstract-resume.js +++ b/dist/core/abstract-resume.js @@ -83,10 +83,10 @@ Definition of the AbstractResume class. if (!this.isLeaf) { if (this.node.ignore === true || this.node.ignore === 'true') { ignoreList.push(this.node); - return this.remove(); + this["delete"](); } else if ((this.node["private"] === true || this.node["private"] === 'true') && !includePrivates) { privateList.push(this.node); - return this.remove(); + this["delete"](); } } }); diff --git a/src/core/abstract-resume.coffee b/src/core/abstract-resume.coffee index 9571457..86b0e0f 100644 --- a/src/core/abstract-resume.coffee +++ b/src/core/abstract-resume.coffee @@ -69,10 +69,11 @@ class AbstractResume if !@isLeaf if @node.ignore == true || @node.ignore == 'true' ignoreList.push @node - @remove() + @delete() else if (@node.private == true || @node.private == 'true') && !includePrivates privateList.push @node - @remove() + @delete() + return scrubbed: scrubbed ingoreList: ignoreList