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

Austria causes crash #365

Open
SimZal opened this issue Nov 4, 2021 · 0 comments
Open

Austria causes crash #365

SimZal opened this issue Nov 4, 2021 · 0 comments

Comments

@SimZal
Copy link

SimZal commented Nov 4, 2021

New browsers support array function at().
This causes error when "at" is present as country code, but not present on map:
jquery.vmap.min.js:10 Uncaught TypeError: this.countries[d].setFill is not a function
or
jquery.vmap.min.js:10 Uncaught TypeError: this.countries[code].setFill is not a function

To fix, in unminified version replace
if (this.countries[code]) {
with
if (this.countries.hasOwnProperty(code)) {

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant