Allow zoomToEntity to be called w/o Extent

In case user clicks on Entity description - line 102
This commit is contained in:
Bryan Housel
2015-04-27 11:46:11 -04:00
parent cecdc012ee
commit b087e78528
+5 -1
View File
@@ -218,7 +218,11 @@ iD.ui.Conflicts = function(context) {
var entity = context.graph().hasEntity(id);
if (entity) {
context.map().trimmedExtent(extent);
if (extent) {
context.map().trimmedExtent(extent);
} else {
context.map().zoomTo(entity);
}
context.surface().selectAll(
iD.util.entityOrMemberSelector([entity.id], context.graph()))
.classed('hover', true);