diff --git a/js/components/eiti-data-map.js b/js/components/eiti-data-map.js index 52adc94a1..36a963b15 100644 --- a/js/components/eiti-data-map.js +++ b/js/components/eiti-data-map.js @@ -248,7 +248,11 @@ .attr('class', 'legendScale'); } - legendScale.call(legend); + try { + legendScale.call(legend); + } catch (error) { + console.warn('legend error:', error); + } } else { console.warn('this element does not have an associated svg legend.');