Skip to content

Commit f132711

Browse files
authored
improve unknown scheme errors (#1087)
Authored-by: Mike Bostock <[email protected]>
1 parent d4f0a8a commit f132711

File tree

1 file changed

+2
-2
lines changed

1 file changed

+2
-2
lines changed

src/scales/schemes.js

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -176,7 +176,7 @@ function schemeicyclical(interpolate) {
176176

177177
export function ordinalScheme(scheme) {
178178
const s = `${scheme}`.toLowerCase();
179-
if (!ordinalSchemes.has(s)) throw new Error(`unknown scheme: ${s}`);
179+
if (!ordinalSchemes.has(s)) throw new Error(`unknown ordinal scheme: ${s}`);
180180
return ordinalSchemes.get(s);
181181
}
182182

@@ -255,7 +255,7 @@ const quantitativeSchemes = new Map([
255255

256256
export function quantitativeScheme(scheme) {
257257
const s = `${scheme}`.toLowerCase();
258-
if (!quantitativeSchemes.has(s)) throw new Error(`unknown scheme: ${s}`);
258+
if (!quantitativeSchemes.has(s)) throw new Error(`unknown quantitative scheme: ${s}`);
259259
return quantitativeSchemes.get(s);
260260
}
261261

0 commit comments

Comments
 (0)