Skip to content

Update dependencies for SignatureMintERC1155; Correct function mutability #223

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Merged
merged 2 commits into from
Aug 24, 2022
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion contracts/base/ERC721Multiwrap.sol
Original file line number Diff line number Diff line change
Expand Up @@ -203,7 +203,7 @@ contract ERC721Multiwrap is Multicall, TokenStore, SoulboundERC721A, ERC721A, Co
}

/// @dev Returns whether transfers can be restricted in a given execution context.
function _canRestrictTransfers() internal virtual override returns (bool) {
function _canRestrictTransfers() internal view virtual override returns (bool) {
return msg.sender == owner();
}

Expand Down
2 changes: 1 addition & 1 deletion contracts/extension/ContractMetadata.sol
Original file line number Diff line number Diff line change
Expand Up @@ -39,5 +39,5 @@ abstract contract ContractMetadata is IContractMetadata {
}

/// @dev Returns whether contract metadata can be set in the given execution context.
function _canSetContractURI() internal virtual returns (bool);
function _canSetContractURI() internal view virtual returns (bool);
}
2 changes: 1 addition & 1 deletion contracts/extension/Drop.sol
Original file line number Diff line number Diff line change
Expand Up @@ -316,5 +316,5 @@ abstract contract Drop is IDrop {
returns (uint256 startTokenId);

/// @dev Determine what wallet can update claim conditions
function _canSetClaimConditions() internal virtual returns (bool);
function _canSetClaimConditions() internal view virtual returns (bool);
}
2 changes: 1 addition & 1 deletion contracts/extension/DropSinglePhase.sol
Original file line number Diff line number Diff line change
Expand Up @@ -252,5 +252,5 @@ abstract contract DropSinglePhase is IDropSinglePhase {
virtual
returns (uint256 startTokenId);

function _canSetClaimConditions() internal virtual returns (bool);
function _canSetClaimConditions() internal view virtual returns (bool);
}
2 changes: 1 addition & 1 deletion contracts/extension/DropSinglePhase1155.sol
Original file line number Diff line number Diff line change
Expand Up @@ -272,5 +272,5 @@ abstract contract DropSinglePhase1155 is IDropSinglePhase1155 {
uint256 _quantityBeingClaimed
) internal virtual;

function _canSetClaimConditions() internal virtual returns (bool);
function _canSetClaimConditions() internal view virtual returns (bool);
}
2 changes: 1 addition & 1 deletion contracts/extension/Ownable.sol
Original file line number Diff line number Diff line change
Expand Up @@ -49,5 +49,5 @@ abstract contract Ownable is IOwnable {
}

/// @dev Returns whether owner can be set in the given execution context.
function _canSetOwner() internal virtual returns (bool);
function _canSetOwner() internal view virtual returns (bool);
}
2 changes: 1 addition & 1 deletion contracts/extension/PlatformFee.sol
Original file line number Diff line number Diff line change
Expand Up @@ -51,5 +51,5 @@ abstract contract PlatformFee is IPlatformFee {
}

/// @dev Returns whether platform fee info can be set in the given execution context.
function _canSetPlatformFeeInfo() internal virtual returns (bool);
function _canSetPlatformFeeInfo() internal view virtual returns (bool);
}
2 changes: 1 addition & 1 deletion contracts/extension/PrimarySale.sol
Original file line number Diff line number Diff line change
Expand Up @@ -41,5 +41,5 @@ abstract contract PrimarySale is IPrimarySale {
}

/// @dev Returns whether primary sale recipient can be set in the given execution context.
function _canSetPrimarySaleRecipient() internal virtual returns (bool);
function _canSetPrimarySaleRecipient() internal view virtual returns (bool);
}
2 changes: 1 addition & 1 deletion contracts/extension/Royalty.sol
Original file line number Diff line number Diff line change
Expand Up @@ -130,5 +130,5 @@ abstract contract Royalty is IRoyalty {
}

/// @dev Returns whether royalty info can be set in the given execution context.
function _canSetRoyaltyInfo() internal virtual returns (bool);
function _canSetRoyaltyInfo() internal view virtual returns (bool);
}
4 changes: 1 addition & 3 deletions contracts/extension/SignatureMintERC1155.sol
Original file line number Diff line number Diff line change
Expand Up @@ -2,9 +2,7 @@
pragma solidity ^0.8.0;

import "./interface/ISignatureMintERC1155.sol";

import "@openzeppelin/contracts/utils/cryptography/ECDSA.sol";
import "@openzeppelin/contracts/utils/cryptography/draft-EIP712.sol";
import "../openzeppelin-presets/utils/cryptography/EIP712.sol";

abstract contract SignatureMintERC1155 is EIP712, ISignatureMintERC1155 {
using ECDSA for bytes32;
Expand Down
2 changes: 1 addition & 1 deletion contracts/extension/SoulboundERC721A.sol
Original file line number Diff line number Diff line change
Expand Up @@ -35,7 +35,7 @@ abstract contract SoulboundERC721A is PermissionsEnumerable {
}

/// @dev Returns whether transfers can be restricted in a given execution context.
function _canRestrictTransfers() internal virtual returns (bool);
function _canRestrictTransfers() internal view virtual returns (bool);

/// @dev See {ERC721A-_beforeTokenTransfers}.
function _beforeTokenTransfers(
Expand Down
2 changes: 1 addition & 1 deletion src/test/sdk/extension/ContractMetadata.t.sol
Original file line number Diff line number Diff line change
Expand Up @@ -13,7 +13,7 @@ contract MyContractMetadata is ContractMetadata {
condition = _condition;
}

function _canSetContractURI() internal override returns (bool) {
function _canSetContractURI() internal view override returns (bool) {
return condition;
}
}
Expand Down
2 changes: 1 addition & 1 deletion src/test/sdk/extension/DropSinglePhase.t.sol
Original file line number Diff line number Diff line change
Expand Up @@ -13,7 +13,7 @@ contract MyDropSinglePhase is DropSinglePhase {
condition = _condition;
}

function _canSetClaimConditions() internal override returns (bool) {
function _canSetClaimConditions() internal view override returns (bool) {
return condition;
}

Expand Down
2 changes: 1 addition & 1 deletion src/test/sdk/extension/DropSinglePhase1155.t.sol
Original file line number Diff line number Diff line change
Expand Up @@ -13,7 +13,7 @@ contract MyDropSinglePhase1155 is DropSinglePhase1155 {
condition = _condition;
}

function _canSetClaimConditions() internal override returns (bool) {
function _canSetClaimConditions() internal view override returns (bool) {
return condition;
}

Expand Down
2 changes: 1 addition & 1 deletion src/test/sdk/extension/Ownable.t.sol
Original file line number Diff line number Diff line change
Expand Up @@ -13,7 +13,7 @@ contract MyOwnable is Ownable {
condition = _condition;
}

function _canSetOwner() internal override returns (bool) {
function _canSetOwner() internal view override returns (bool) {
return condition;
}
}
Expand Down
2 changes: 1 addition & 1 deletion src/test/sdk/extension/PlatformFee.t.sol
Original file line number Diff line number Diff line change
Expand Up @@ -13,7 +13,7 @@ contract MyPlatformFee is PlatformFee {
condition = _condition;
}

function _canSetPlatformFeeInfo() internal override returns (bool) {
function _canSetPlatformFeeInfo() internal view override returns (bool) {
return condition;
}
}
Expand Down
2 changes: 1 addition & 1 deletion src/test/sdk/extension/PrimarySale.t.sol
Original file line number Diff line number Diff line change
Expand Up @@ -13,7 +13,7 @@ contract MyPrimarySale is PrimarySale {
condition = _condition;
}

function _canSetPrimarySaleRecipient() internal override returns (bool) {
function _canSetPrimarySaleRecipient() internal view override returns (bool) {
return condition;
}
}
Expand Down
2 changes: 1 addition & 1 deletion src/test/sdk/extension/Royalty.t.sol
Original file line number Diff line number Diff line change
Expand Up @@ -13,7 +13,7 @@ contract MyRoyalty is Royalty {
condition = _condition;
}

function _canSetRoyaltyInfo() internal override returns (bool) {
function _canSetRoyaltyInfo() internal view override returns (bool) {
return condition;
}

Expand Down