diff --git a/react/features/deep-linking/components/DeepLinkingMobilePage.web.js b/react/features/deep-linking/components/DeepLinkingMobilePage.web.js index daac4b67d..ec239d1d0 100644 --- a/react/features/deep-linking/components/DeepLinkingMobilePage.web.js +++ b/react/features/deep-linking/components/DeepLinkingMobilePage.web.js @@ -40,6 +40,11 @@ type Props = { */ _room: string, + /** + * The page current url. + */ + _url: URL, + /** * Used to dispatch actions from the buttons. */ @@ -90,7 +95,7 @@ class DeepLinkingMobilePage extends Component { * @returns {ReactElement} */ render() { - const { _downloadUrl, _room, t } = this.props; + const { _downloadUrl, _room, t, _url } = this.props; const { HIDE_DEEP_LINKING_LOGO, NATIVE_APP_NAME, SHOW_DEEP_LINKING_IMAGE } = interfaceConfig; const downloadButtonClassName = `${_SNS}__button ${_SNS}__button_primary`; @@ -181,7 +186,8 @@ class DeepLinkingMobilePage extends Component { + room = { _room } + url = { _url } /> ); @@ -274,9 +280,12 @@ class DeepLinkingMobilePage extends Component { * @returns {Props} */ function _mapStateToProps(state) { + const { locationURL = {} } = state['features/base/connection']; + return { _downloadUrl: interfaceConfig[`MOBILE_DOWNLOAD_LINK_${Platform.OS.toUpperCase()}`], - _room: decodeURIComponent(state['features/base/conference'].room) + _room: decodeURIComponent(state['features/base/conference'].room), + _url: locationURL }; } diff --git a/react/features/invite/components/dial-in-summary/web/DialInSummary.js b/react/features/invite/components/dial-in-summary/web/DialInSummary.js index ad39cd082..64865af46 100644 --- a/react/features/invite/components/dial-in-summary/web/DialInSummary.js +++ b/react/features/invite/components/dial-in-summary/web/DialInSummary.js @@ -33,7 +33,7 @@ type Props = { /** * The url where we were loaded. */ - url: string, + url: URL | string, /** * Invoked to obtain translated strings. @@ -182,7 +182,14 @@ class DialInSummary extends Component { return Promise.resolve(); } - return getDialInConferenceID(dialInConfCodeUrl, room, mucURL, new URL(this.props.url)) + + let url = this.props.url || {}; + + if (typeof url === 'string' || url instanceof String) { + url = new URL(url); + } + + return getDialInConferenceID(dialInConfCodeUrl, room, mucURL, url) .catch(() => Promise.reject(this.props.t('info.genericError'))); }