Remove unnecessary code

This commit is contained in:
Zach Fox 2017-08-31 15:42:32 -07:00
parent 2c2500875f
commit 0a9e3e8967
4 changed files with 5 additions and 25 deletions

View file

@ -62,7 +62,6 @@ Rectangle {
if (!exists && root.activeView !== "notSetUp") { // "If security image is not set up"
root.activeView = "notSetUp";
} else if (exists && root.activeView === "initialize") {
root.activeView = "checkoutMain";
commerce.getWalletAuthenticatedStatus();
} else if (exists) {
// just set the source again (to be sure the change was noticed)
@ -75,6 +74,7 @@ Rectangle {
if (!isAuthenticated && !passphraseModal.visible) {
passphraseModal.visible = true;
} else if (isAuthenticated) {
root.activeView = "checkoutMain";
if (!balanceReceived) {
commerce.balance();
}
@ -235,16 +235,7 @@ Rectangle {
Connections {
onSendSignalToParent: {
if (msg.method === 'passphraseModal_authSuccess') {
if (!balanceReceived) {
commerce.balance();
}
if (!purchasesReceived) {
commerce.inventory();
}
} else {
sendToScript(msg);
}
sendToScript(msg);
}
}
}

View file

@ -57,7 +57,6 @@ Rectangle {
if (!exists && root.activeView !== "notSetUp") { // "If security image is not set up"
root.activeView = "notSetUp";
} else if (exists && root.activeView === "initialize") {
root.activeView = "purchasesMain";
commerce.getWalletAuthenticatedStatus();
} else if (exists) {
// just set the source again (to be sure the change was noticed)
@ -70,6 +69,7 @@ Rectangle {
if (!isAuthenticated && !passphraseModal.visible) {
passphraseModal.visible = true;
} else if (isAuthenticated) {
root.activeView = "purchasesMain";
commerce.inventory();
}
}
@ -206,13 +206,7 @@ Rectangle {
Connections {
onSendSignalToParent: {
if (msg.method === 'passphraseModal_authSuccess') {
if (!purchasesReceived) {
commerce.inventory();
}
} else {
sendToScript(msg);
}
sendToScript(msg);
}
}
}

View file

@ -41,7 +41,6 @@ Item {
errorText.text = "Authentication failed - please try again.";
} else {
root.visible = false;
sendSignalToParent({method: 'passphraseModal_authSuccess'});
}
}
}

View file

@ -232,11 +232,7 @@ Rectangle {
Connections {
onSendSignalToParent: {
if (msg.method === 'passphraseModal_authSuccess') {
root.activeView = "walletHome";
} else {
sendToScript(msg);
}
sendToScript(msg);
}
}
}