Skip to content

Commit e569d43

Browse files
committed
handle empty
1 parent 00232af commit e569d43

File tree

2 files changed

+2
-0
lines changed

2 files changed

+2
-0
lines changed

Diff for: src/components/drawing/index.js

+1
Original file line numberDiff line numberDiff line change
@@ -1775,6 +1775,7 @@ function getMarkerAngle(d, trace) {
17751775
}
17761776

17771777
if(trace._geo) {
1778+
if(!d.latlon) return null;
17781779
var lon = d.lonlat[0];
17791780
var lat = d.lonlat[1];
17801781

Diff for: src/plots/geo/geo.js

+1
Original file line numberDiff line numberDiff line change
@@ -553,6 +553,7 @@ proto.makeFramework = function() {
553553

554554
// sane lonlat to px
555555
_this.project = function(v) {
556+
if(!v) return [null, null];
556557
var px = _this.projection(v);
557558
return px ?
558559
[px[0] - _this.xaxis._offset, px[1] - _this.yaxis._offset] :

0 commit comments

Comments
 (0)