Fixed the consensus about expired domains.

This commit is contained in:
Revertron
2022-09-05 19:12:46 +02:00
parent beb09ed01c
commit a612f73649
9 changed files with 121 additions and 101 deletions
+4 -1
View File
@@ -126,7 +126,10 @@ fn action_check_domain(context: &Arc<Mutex<Context>>, web_view: &mut WebView<()>
let c = context.lock().unwrap();
if let Some(keystore) = c.get_keystore() {
let name = name.to_lowercase();
let available = c.get_chain().is_domain_available(c.get_chain().get_height(), &name, &keystore.get_public());
let available = match c.chain.can_mine_domain(c.chain.get_height(), &name, &keystore.get_public()) {
MineResult::Fine => true,
_ => false
};
web_view.eval(&format!("domainAvailable({})", available)).expect("Error evaluating!");
}
}