Skip to content

Commit

Permalink
optimizations
Browse files Browse the repository at this point in the history
  • Loading branch information
ZumZoom committed Mar 21, 2024
1 parent d0506f4 commit f037233
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions contracts/libraries/AddressArray.sol
Original file line number Diff line number Diff line change
Expand Up @@ -92,7 +92,7 @@ library AddressArray {

switch len
case 0 {
sstore(self.slot, or(or(account, _ONE_LENGTH), _ZERO_ADDRESS))
sstore(self.slot, or(account, _ONE_LENGTH))
}
default {
sstore(self.slot, add(lengthAndFirst, _ONE_LENGTH))
Expand All @@ -115,7 +115,7 @@ library AddressArray {
exception := true
}
case 1 {
res := and(sload(self.slot), _ADDRESS_MASK)
res := and(lengthAndFirst, _ADDRESS_MASK)
sstore(self.slot, _ZERO_ADDRESS)
}
default {
Expand Down

0 comments on commit f037233

Please sign in to comment.