Wizard: fix stagenet getApproximateBlockchainHeight

This commit is contained in:
selsta 2024-04-28 21:13:18 +02:00
parent f0b1b8cd08
commit 7a3ea3a93c
No known key found for this signature in database
GPG Key ID: 2EA0A99A8B07AE5E

View File

@ -166,7 +166,7 @@ function getApproximateBlockchainHeight(_date, _nettype){
if(_nettype == "Testnet" || _nettype == "Stagenet"){
// testnet got some huge rollbacks, so the estimation is way off
var approximateTestnetRolledBackBlocks = _nettype == "Testnet" ? 342100 : 30000;
var approximateTestnetRolledBackBlocks = _nettype == "Testnet" ? 342100 : _nettype == "Stagenet" ? 60000 : 30000;
if(approxBlockchainHeight > approximateTestnetRolledBackBlocks)
approxBlockchainHeight -= approximateTestnetRolledBackBlocks
}