Merge pull request #6757 from hajjimurad/master
Fix crashing on creation of snap-interaction, if Circle is among the features to snap to.
This commit is contained in:
@@ -418,8 +418,10 @@ ol.interaction.Snap.prototype.updateFeature_ = function(feature) {
|
|||||||
ol.interaction.Snap.prototype.writeGeometryCollectionGeometry_ = function(feature, geometry) {
|
ol.interaction.Snap.prototype.writeGeometryCollectionGeometry_ = function(feature, geometry) {
|
||||||
var i, geometries = geometry.getGeometriesArray();
|
var i, geometries = geometry.getGeometriesArray();
|
||||||
for (i = 0; i < geometries.length; ++i) {
|
for (i = 0; i < geometries.length; ++i) {
|
||||||
this.SEGMENT_WRITERS_[geometries[i].getType()].call(
|
var segmentWriter = this.SEGMENT_WRITERS_[geometries[i].getType()];
|
||||||
this, feature, geometries[i]);
|
if (segmentWriter) {
|
||||||
|
segmentWriter.call(this, feature, geometries[i]);
|
||||||
|
}
|
||||||
}
|
}
|
||||||
};
|
};
|
||||||
|
|
||||||
|
|||||||
Reference in New Issue
Block a user