Skip to content

Commit

Permalink
fix: store check _amount (#6)
Browse files Browse the repository at this point in the history
  • Loading branch information
maximebrugel committed Feb 16, 2022
1 parent e82319e commit 0c71774
Showing 1 changed file with 1 addition and 0 deletions.
1 change: 1 addition & 0 deletions contracts/NestedRecords.sol
Original file line number Diff line number Diff line change
Expand Up @@ -114,6 +114,7 @@ contract NestedRecords is OwnableFactoryHandler {
uint256 _amount,
address _reserve
) external onlyFactory {
require(_amount != 0, "NRC: INVALID_AMOUNT");
uint256 amount = records[_nftId].holdings[_token];
if (amount != 0) {
require(records[_nftId].reserve == _reserve, "NRC: RESERVE_MISMATCH");
Expand Down

0 comments on commit 0c71774

Please sign in to comment.