contract Allowable is Ownable {
    
    // Contains details regarding allowed addresses
    mapping (address => mapping(uint256 => bool) )public permissions;
    // Active status
    bool public isActive = true;

    /**
    * @dev Reverts if an address is not allowed. Can be used when extending this contract.
    */
    
    modifier whenActive(address _from,address _to,uint256 tokenId){
        require (!permissions[_from][tokenId] && !permissions[_to][tokenId] );          
        _;
    }
    
    modifier active(){
            require(isActive, "Not Active");            
        _;
    }
    
    /**
    * @dev Adds single address to the permissions list. Allowed only for contract owner.
    * @param _operator Address to be added to the permissions list
    */
    function allow(address _operator,uint256 _tokenId) external onlyOwner {
        permissions[_operator][_tokenId] = false;
    }
    
    /**
    * @dev Removes single address from an permissions list. Allowed only for contract owner.  
    * @param _operator Address to be removed from the permissions list
    */
    function deny(address _operator,uint256 _tokenId) external onlyOwner {
         permissions[_operator][_tokenId] = true;
    }
    
    /**
    * @dev Sets active status of the contract. Allowed only for contract owner.  
    * @param _status Status of the contract
    */
    function activate(bool _status) onlyOwner public {
        isActive = _status;
    }
    
}
function allow(address _operator,uint256 _tokenId) external onlyOwner {
    permissions[_operator][_tokenId] = false;
}

/**
 * @dev Adds single address to the permissions list. Allowed only for contract owner.
 * @param _operator Address to be added to the permissions list
 */