Skip to content

Interactive interface for browsing global, full-resolution satellite imagery

dont fly to extent before updating proj (#3879)

Jason Kent72f2242291b7
diff --git a/web/js/map/ui.js b/web/js/map/ui.js
index a1821abca..8a252a31b 100644
--- a/web/js/map/ui.js
+++ b/web/js/map/ui.js
@@ -173,10 +173,13 @@ export default function mapui(models, config, store) {
const newState = util.fromQueryString(action.payload.search);
const extent = lodashGet(state, 'map.extent');
const rotate = lodashGet(state, 'map.rotation') || 0;
- setTimeout(updateProjection, 200);
- if (newState.v && !newState.e && extent) {
- flyToNewExtent(extent, rotate);
- }
+ setTimeout(() => {
+ updateProjection();
+ if (newState.v && !newState.e && extent) {
+ flyToNewExtent(extent, rotate);
+ }
+ }, 200);
+
return;
}
case layerConstants.REMOVE_GROUP: