From ae012757296b7c82effae145a46adf1120d13bb7 Mon Sep 17 00:00:00 2001 From: damencho Date: Tue, 1 Nov 2016 14:46:47 -0500 Subject: [PATCH] Renames variables. --- conference.js | 13 +++++++------ modules/UI/UI.js | 11 ++++++----- 2 files changed, 13 insertions(+), 11 deletions(-) diff --git a/conference.js b/conference.js index 484497495..b91fba106 100644 --- a/conference.js +++ b/conference.js @@ -185,14 +185,15 @@ function muteLocalVideo (muted) { * If we have a close page enabled, redirect to it without * showing any other dialog. * - * @param {object} data Feedback data - * @param {boolean} data.showThankYou - whether we should show thank you dialog - * @param {boolean} data.feedbackSubmitted - whether feedback was submitted + * @param {object} options Feedback data + * @param {boolean} options.thankYouDialogVisible - whether we should + * show thank you dialog + * @param {boolean} options.feedbackSubmitted - whether feedback was submitted */ -function maybeRedirectToWelcomePage(data) { +function maybeRedirectToWelcomePage(options) { // if close page is enabled redirect to it, without further action if (config.enableClosePage) { - if (data.feedbackSubmitted) + if (options.feedbackSubmitted) window.location.pathname = "close.html"; else window.location.pathname = "close2.html"; @@ -200,7 +201,7 @@ function maybeRedirectToWelcomePage(data) { } // else: show thankYou dialog only if there is no feedback - if (data.showThankYou) + if (options.thankYouDialogVisible) APP.UI.messageHandler.openMessageDialog( null, "dialog.thankYou", {appName:interfaceConfig.APP_NAME}); diff --git a/modules/UI/UI.js b/modules/UI/UI.js index b33356d7e..1b90e865d 100644 --- a/modules/UI/UI.js +++ b/modules/UI/UI.js @@ -1039,7 +1039,7 @@ UI.requestFeedbackOnHangup = function () { // Feedback has been submitted already. else if (Feedback.isEnabled() && Feedback.isSubmitted()) { return Promise.resolve({ - showThankYou : true, + thankYouDialogVisible : true, feedbackSubmitted: true }); } @@ -1047,15 +1047,16 @@ UI.requestFeedbackOnHangup = function () { return new Promise(function (resolve) { if (Feedback.isEnabled()) { Feedback.openFeedbackWindow( - (data) => { - data.showThankYou = false; - resolve(data); + (options) => { + options.thankYouDialogVisible = false; + resolve(options); }); } else { // If the feedback functionality isn't enabled we show a thank // you dialog. Signaling it (true), so the caller // of requestFeedback can act on it - resolve({showThankYou : true, feedbackSubmitted: false}); + resolve( + {thankYouDialogVisible : true, feedbackSubmitted: false}); } }); };