fix merkle tree capacity

This commit is contained in:
Drygin 2019-09-04 13:31:10 +03:00
parent 51b06ed661
commit ec30e2d357
1 changed files with 1 additions and 1 deletions

View File

@ -58,7 +58,7 @@ contract MerkleTreeWithHistory {
function _insert(uint256 leaf) internal {
uint32 current_index = next_index;
require(current_index != 2**(levels - 1), "Merkle tree is full");
require(current_index != 2**levels, "Merkle tree is full");
next_index += 1;
uint256 current_level_hash = leaf;
uint256 left;