Merge pull request #1224 from jitsi/fix-close-page-redirect

Removes guest parameter when navigating to close page.
This commit is contained in:
yanas 2017-01-03 14:37:54 -06:00 committed by GitHub
commit 414a978b10
4 changed files with 7 additions and 9 deletions

View File

@ -3,7 +3,6 @@
<link rel="stylesheet" href="css/all.css"/> <link rel="stylesheet" href="css/all.css"/>
<!--#include virtual="title.html" --> <!--#include virtual="title.html" -->
<script><!--#include virtual="/interface_config.js" --></script> <script><!--#include virtual="/interface_config.js" --></script>
<script src="utils.js?v=1"></script>
<script src="close.js"></script> <script src="close.js"></script>
</head> </head>
<body> <body>

View File

@ -1,4 +1,4 @@
/* global interfaceConfig, getConfigParamsFromUrl */ /* global interfaceConfig */
//list of tips //list of tips
var hints = [ var hints = [
"You can pin participants by clicking on their thumbnails.",// jshint ignore:line "You can pin participants by clicking on their thumbnails.",// jshint ignore:line
@ -45,8 +45,7 @@ function onLoad() {
// If there is a setting show a special message only for the guests // If there is a setting show a special message only for the guests
if (interfaceConfig.CLOSE_PAGE_GUEST_HINT) { if (interfaceConfig.CLOSE_PAGE_GUEST_HINT) {
let params = getConfigParamsFromUrl('search'); if ( window.sessionStorage.getItem('guest') === 'true' ) {
if ( params.guest ) {
var element = document.getElementById('hintQuestion'); var element = document.getElementById('hintQuestion');
element.classList.add('hide'); element.classList.add('hide');
insertTextMsg('hintMessage', interfaceConfig.CLOSE_PAGE_GUEST_HINT); insertTextMsg('hintMessage', interfaceConfig.CLOSE_PAGE_GUEST_HINT);

View File

@ -3,7 +3,6 @@
<link rel="stylesheet" href="css/all.css"/> <link rel="stylesheet" href="css/all.css"/>
<!--#include virtual="title.html" --> <!--#include virtual="title.html" -->
<script><!--#include virtual="/interface_config.js" --></script> <script><!--#include virtual="/interface_config.js" --></script>
<script src="utils.js?v=1"></script>
<script src="close.js"></script> <script src="close.js"></script>
</head> </head>
<body> <body>

View File

@ -195,12 +195,13 @@ function muteLocalVideo (muted) {
function maybeRedirectToWelcomePage(options) { function maybeRedirectToWelcomePage(options) {
// if close page is enabled redirect to it, without further action // if close page is enabled redirect to it, without further action
if (config.enableClosePage) { if (config.enableClosePage) {
// save whether current user is guest or not, before navigating
// to close page
window.sessionStorage.setItem('guest', APP.tokenData.isGuest);
if (options.feedbackSubmitted) if (options.feedbackSubmitted)
window.location.pathname = "close.html?guest=" window.location.pathname = "close.html";
+ APP.tokenData.isGuest;
else else
window.location.pathname = "close2.html?guest=" window.location.pathname = "close2.html";
+ APP.tokenData.isGuest;
return; return;
} }