Interactive interface for browsing global, full-resolution satellite imagery
wait for shortlink request promise to resolve
Ed Plato814643066207
diff --git a/web/js/containers/share.js b/web/js/containers/share.jsindex e173474fc..f3943d892 100644--- a/web/js/containers/share.js+++ b/web/js/containers/share.js@@ -84,13 +84,14 @@ class ShareLinkContainer extends Component {onToggleShorten = () => {const { shortLinkKey, isShort, queryString } = this.state;if (!isShort && shortLinkKey !== queryString) {- this.getShortLink();- googleTagManager.pushEvent({- event: 'social_link_shorten',- });- this.setState({- shortLinkKey: queryString,- isShort: !isShort,+ this.getShortLink().then(() => {+ googleTagManager.pushEvent({+ event: 'social_link_shorten',+ });+ this.setState({+ shortLinkKey: queryString,+ isShort: !isShort,+ });});} else {this.setState({