diff --git a/lib/algorithm.js b/lib/algorithm.js index 0794bec..6069251 100644 --- a/lib/algorithm.js +++ b/lib/algorithm.js @@ -101,8 +101,10 @@ class Algorithm { return this.#wantNewestRange(localHave, remoteHave, goal.count) case 'none': - default: return EMPTY_RANGE + + default: + throw new Error(`Unrecognized goal type: ${goal.type}`) } }