mirror of
https://github.com/Doodle3D/doodle3d-connect.git
synced 2024-11-16 11:07:57 +01:00
Fixed check on connecting to network page
It should now only redirect to home when the network is encrypted and there is no form data (or there are no url params).
This commit is contained in:
parent
2de7bc1fc3
commit
83a9a37a3d
@ -39,8 +39,13 @@
|
||||
console.log(PAGE_ID+": pagebeforeshow");
|
||||
_pageData = d3d.util.getPageParams(PAGE_ID);
|
||||
var form = data.prevPage.find("form");
|
||||
// check if there are url params and a form from a prev page
|
||||
if(_pageData === undefined || form.length === 0) {
|
||||
// check if there are url params and
|
||||
// when encrypted if there was a form from a prev page
|
||||
if(_pageData.encryption === "") {
|
||||
_pageData.encryption = "none";
|
||||
}
|
||||
if(_pageData === undefined ||
|
||||
(_pageData.encryption !== "none" && form.length === 0)) {
|
||||
$.mobile.changePage("#boxes");
|
||||
return;
|
||||
}
|
||||
|
@ -73,8 +73,8 @@
|
||||
var secured = (network.encryption !== "none" && network.encryption !== "");
|
||||
var link;
|
||||
var icon = "";
|
||||
linkParams.encryption = network.encryption;
|
||||
if(secured) {
|
||||
linkParams.encryption = network.encryption;
|
||||
link = d3d.util.replaceURLParameters(baseSecuredLink,linkParams);
|
||||
icon = "lock";
|
||||
} else {
|
||||
|
Loading…
Reference in New Issue
Block a user