minor link bug fix, as well as some changes to allow the use of alt coins with out throwing an error

This commit is contained in:
OutCast3k 2015-05-20 13:05:19 +00:00
parent b7e737a76b
commit 8fed2612d5
2 changed files with 9 additions and 8 deletions

View File

@ -810,8 +810,11 @@ $(document).ready(function() {
function decodeHDaddress(){
var s = $("#verifyScript").val();
if(s.match(/^x[prv|pub]/)){
try {
try {
var hex = Crypto.util.bytesToHex((coinjs.base58decode(s)).slice(0,4));
var hex_cmp_prv = Crypto.util.bytesToHex((coinjs.numToBytes(coinjs.hdkey.prv,4)).reverse());
var hex_cmp_pub = Crypto.util.bytesToHex((coinjs.numToBytes(coinjs.hdkey.pub,4)).reverse());
if(hex == hex_cmp_prv || hex == hex_cmp_pub){
var hd = coinjs.hd(s);
$("#verifyHDaddress .hdKey").html(s);
$("#verifyHDaddress .chain_code").val(Crypto.util.bytesToHex(hd.chain_code));
@ -826,9 +829,9 @@ $(document).ready(function() {
$(".verifyLink").attr('href','?verify='+$("#verifyScript").val());
$("#verifyHDaddress").removeClass("hidden");
return true;
} catch (e) {
return false;
}
} catch (e) {
return false;
}
}
@ -907,6 +910,7 @@ $(document).ready(function() {
return r;
}
$("#newKeysBtn, #newHDKeysBtn").click();
var _getBroadcast = _get("broadcast");
if(_getBroadcast[0]){
@ -966,9 +970,6 @@ $(document).ready(function() {
$(".pubkeyAdd").click();
}
$("#newKeysBtn, #newHDKeysBtn").click();
validateOutputAmount();
/* capture mouse movement to add entropy */

View File

@ -11,7 +11,7 @@ ad038e1f39646b68ae666324ed4c2882a8c42474 ./js/qrcode.js
64eb4ea5c882f8bce3e1885bf00728455f1c2f4c ./js/ripemd160.js
114089ef2a3feb6d4db4f9cabcb186d7750d5884 ./js/sha512.js
782ecafc45b2e791451b9d43659c815c76d4816d ./js/coin.js
8e921b2156d232871540e168e1677368b5611dc9 ./js/coinbin.js
8b773f26bf402a99404b967009b83d7d0741d392 ./js/coinbin.js
ae49e56999d82802727455f0ba83b63acd90a22b ./js/jquery-1.9.1.min.js
5f570018ed044eafd464f7e0ab1783b966224055 ./LICENCE
ed29315e0ffb3f14382431f2724235bf67f44eb3 ./css/bootstrap.min.css