diff --git a/lib/OpenLayers/Marker.js b/lib/OpenLayers/Marker.js index 8281f01ff7..9a76b44335 100644 --- a/lib/OpenLayers/Marker.js +++ b/lib/OpenLayers/Marker.js @@ -57,7 +57,7 @@ OpenLayers.Marker.prototype = { * @param {OpenLayers.Pixel} px */ moveTo: function (px) { - if ((px != null) && (this.div != null)) { + if ((px != null) && (this.image != null)) { this.image.style.top = (px.y + this.icon.offset.y) + "px" this.image.style.left = (px.x + this.icon.offset.x) + "px"; }