Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Clean up factor range and add factor method #14037

Merged
merged 15 commits into from
Aug 27, 2024
Prev Previous commit
Next Next commit
better error type
  • Loading branch information
bryevdv committed Aug 27, 2024
commit fd611431f8404eb420653f5f3e1ed325897336ee
2 changes: 1 addition & 1 deletion bokehjs/src/lib/models/ranges/factor_range.ts
Original file line number Diff line number Diff line change
Expand Up @@ -209,7 +209,7 @@ export abstract class FactorMapper<FactorType> {
})()

if (boxed.length > this.levels) {
throw TypeError(`Attempted to map ${boxed.length} levels of factors with an L${this.levels}FactorMap`)
throw new Error(`Attempted to map ${boxed.length} levels of factors with an L${this.levels}FactorMap`)
}

return this.lookup_value(boxed as BoxedAtMost<FactorType>) + offset
Expand Down