Fix error, pos could be null

This commit is contained in:
Ansis Brammanis
2013-02-08 18:01:45 -05:00
parent 5b646b75c3
commit 334cb9f93b
+1 -1
View File
@@ -59,7 +59,7 @@ iD.behavior.Select = function(context) {
function mouseup() {
selection.on('mousemove.select', null);
if (d3.event.x === pos[0] && d3.event.y === pos[1] &&
if (pos && d3.event.x === pos[0] && d3.event.y === pos[1] &&
!(d3.event.target.__data__ instanceof iD.Entity)) {
context.enter(iD.modes.Browse(context));
}