Skip to content

Commit

Permalink
fix[ui]: redirect and pass confirm bugs
Browse files Browse the repository at this point in the history
  • Loading branch information
sk33z3r committed Jun 26, 2022
1 parent 31d8161 commit fea11e7
Show file tree
Hide file tree
Showing 3 changed files with 8 additions and 3 deletions.
4 changes: 4 additions & 0 deletions php/mint-config/finish.php
Original file line number Diff line number Diff line change
@@ -1,5 +1,9 @@
<?php

if (!file_exists($mint_config)) {
BrowserRedirect('/mint-config/1');
}

if ($_GET['result'] === "0") { ?>
<h3 class="success">Configuration Successfully Encrypted</h3>
<div id="guide">
Expand Down
5 changes: 3 additions & 2 deletions php/transfer-config/1.php
Original file line number Diff line number Diff line change
Expand Up @@ -42,15 +42,16 @@
$sender = $_POST['sender'];
$private_key = $_POST['private_key'];
$secret = base64_encode($_POST['secret']);
$pass_confirm = $_POST['pass_confirm'];
$pass_confirm = base64_encode($_POST['pass_confirm']);
$private_key_mm = $_POST['private_key_mm'];
$fee_token = $_POST['fee_token'];

if ($secret !== $pass_confirm) {
$code = "100";
} else {
if(!str_starts_with($private_key_mm, '0x'))
if(!str_starts_with($private_key_mm, '0x')) {
$private_key_mm = '0x' . $private_key_mm;
}

$config_data = array("sender"=>$sender,
"private_key"=>$private_key,
Expand Down
2 changes: 1 addition & 1 deletion php/transfer-config/finish.php
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
<?php

if (!file_exists($transfer_config) or !isset($_GET['result'])) {
if (!file_exists($transfer_config)) {
BrowserRedirect('/transfer-config/1');
}

Expand Down

0 comments on commit fea11e7

Please sign in to comment.