| 631 | } |
| 632 | |
| 633 | Amount BlockChainState::minimum_pool_fee_per_byte(bool zero_if_not_full, Hash *minimal_tid) const { |
| 634 | if (m_memory_state_fee_tx.empty()) { |
| 635 | if (minimal_tid) |
| 636 | *minimal_tid = Hash{}; |
| 637 | return 0; |
| 638 | } |
| 639 | if (zero_if_not_full && m_memory_state_total_size < m_max_pool_size) { |
| 640 | if (minimal_tid) |
| 641 | *minimal_tid = Hash{}; |
| 642 | return 0; |
| 643 | } |
| 644 | auto be = m_memory_state_fee_tx.begin(); |
| 645 | if (minimal_tid) |
| 646 | *minimal_tid = be->second; |
| 647 | return be->first; |
| 648 | } |
| 649 | |
| 650 | void BlockChainState::on_reorganization( |
| 651 | const std::map<Hash, std::pair<Transaction, BinaryArray>> &undone_transactions, bool undone_blocks) { |
no test coverage detected