Codebase list leaflet / d8c51ad
Throw error on NaN circle radius, #4235 Iván Sánchez Ortega 8 years ago
1 changed file(s) with 2 addition(s) and 0 deletion(s). Raw diff Collapse all Expand all
44 L.Circle = L.Path.extend({
55 initialize: function (latlng, radius, options) {
66 L.Path.prototype.initialize.call(this, options);
7
8 if (isNaN(radius)) { throw new Error('Circle radius cannot be NaN'); }
79
810 this._latlng = L.latLng(latlng);
911 this._mRadius = radius;