Browse Source

ref(conference): change when the room reference is removed (#3808)

Delay removing the room reference. This is in case a
consumer of the API is attempting to submit feedback
after hangup but before redirecting to another page.
If the room reference is removed, feedback submission
will fail during this period.
master
virtuacoplenny 6 years ago
parent
commit
10624e87f5
No account linked to committer's email address
1 changed files with 4 additions and 5 deletions
  1. 4
    5
      conference.js

+ 4
- 5
conference.js View File

@@ -2509,6 +2509,9 @@ export default {
2509 2509
             requestFeedbackPromise,
2510 2510
             this.leaveRoomAndDisconnect()
2511 2511
         ]).then(values => {
2512
+            this._room = undefined;
2513
+            room = undefined;
2514
+
2512 2515
             APP.API.notifyReadyToClose();
2513 2516
             maybeRedirectToWelcomePage(values[0]);
2514 2517
         });
@@ -2523,11 +2526,7 @@ export default {
2523 2526
         APP.store.dispatch(conferenceWillLeave(room));
2524 2527
 
2525 2528
         return room.leave()
2526
-            .then(disconnect, disconnect)
2527
-            .then(() => {
2528
-                this._room = undefined;
2529
-                room = undefined;
2530
-            });
2529
+            .then(disconnect, disconnect);
2531 2530
     },
2532 2531
 
2533 2532
     /**

Loading…
Cancel
Save