Holen Sie sich alle Besitzer, die Token in Solidität haben

function getOwners() public view onlyOwner returns (address[] memory){
        uint256 total = totalSupply();
        address[] memory owners = new address[](total);
        for(uint256 tokenId = 0; tokenId < total; tokenId ++) {
            require(_exists(tokenId), "Token does not exist");
            owners[tokenId] = ownerOf(tokenId);
        }

        return owners;
    }
akileus