Переглянути джерело

code review changes

master
Tudor-Ovidiu Avram 4 роки тому
джерело
коміт
86dd35b927

+ 2
- 0
react/features/invite/actions.any.js Переглянути файл

@@ -104,6 +104,7 @@ export function invite(
104 104
         } = state['features/base/config'];
105 105
         const inviteUrl = getInviteURL(state);
106 106
         const { sipInviteUrl } = state['features/base/config'];
107
+        const { locationURL } = state['features/base/connection'];
107 108
         const { jwt } = state['features/base/jwt'];
108 109
         const { name: displayName } = getLocalParticipant(state);
109 110
 
@@ -172,6 +173,7 @@ export function invite(
172 173
 
173 174
         conference && inviteSipEndpoints(
174 175
             sipEndpoints,
176
+            locationURL,
175 177
             sipInviteUrl,
176 178
             jwt,
177 179
             conference.options.name,

+ 3
- 1
react/features/invite/functions.js Переглянути файл

@@ -808,6 +808,7 @@ export function isSharingEnabled(sharingFeature: string) {
808 808
  * Sends a post request to an invite service.
809 809
  *
810 810
  * @param {Array} inviteItems - The list of the "sip" type items to invite.
811
+ * @param {URL} locationURL - The URL of the location.
811 812
  * @param {string} sipInviteUrl - The invite service that generates the invitation.
812 813
  * @param {string} jwt - The jwt token.
813 814
  * @param {string} roomName - The name to the conference.
@@ -816,6 +817,7 @@ export function isSharingEnabled(sharingFeature: string) {
816 817
  */
817 818
 export function inviteSipEndpoints( // eslint-disable-line max-params
818 819
         inviteItems: Array<Object>,
820
+        locationURL: URL,
819 821
         sipInviteUrl: string,
820 822
         jwt: string,
821 823
         roomName: string,
@@ -825,7 +827,7 @@ export function inviteSipEndpoints( // eslint-disable-line max-params
825 827
         return Promise.resolve();
826 828
     }
827 829
 
828
-    const baseUrl = window.location.href.toLowerCase().replace(`/${roomName}`, '');
830
+    const baseUrl = locationURL.href.toLowerCase().replace(`/${roomName}`, '');
829 831
 
830 832
     return fetch(
831 833
        sipInviteUrl,

Завантаження…
Відмінити
Зберегти