This repository was archived by the owner on Apr 30, 2024. It is now read-only.

Description
There is a term in UML called commercializers, that dictates people can set an address that will determine if the minter/linker/receiver of an LNFT must be part of a known list of addresses.
The methods of determining this list could be varied. Basically, it's a synch hook from alpha, but with a less rigid structure.
- We need an interface such as:
interface ICommercializersChecker {
function isAllowedCommercializer(address candidate, bytes memory data) external view returns (bool);
}
- We need to change
UMLPolicy, substituting commercializers as a string array for:
commercializerChecker: address, // the address of ICommercializersChecker
commercializerData: bytes // abi.encoded data that will be set in the policy
UMLPolicyFrameworkManager must, on verifyMint() and verifyLink(), check that the IPAccount passes isAllowedCommercializer(policy.commercializerChecker, policy,.commercializerData), and uses the value to return true or false
- We can support a
ERC721GatedCommercializersChecker.
-- Singleton contract
function isAllowedCommercializer(address candidate, bytes memory data) external view returns (bool) {
address tokenAddress = abi.decode(data, (address));
return IERC721(tokenAddress).balanceOf(candidate) > 0;
}