refactor(incremental-merkle-tree.sol): remove unnecessary bitwise and operator

re #37
This commit is contained in:
cedoor
2022-12-22 19:24:35 +01:00
parent b8b3726c26
commit 12e16007c6

View File

@@ -104,7 +104,7 @@ library IncrementalBinaryTree {
uint256 updateIndex;
for (uint8 i = 0; i < depth; ) {
updateIndex |= uint256(proofPathIndices[i] & 1) << uint256(i);
updateIndex |= uint256(proofPathIndices[i]) << uint256(i);
if (proofPathIndices[i] == 0) {
if (proofSiblings[i] == self.lastSubtrees[i][1]) {