From ee6e24cd5da62146d5ac11e0dbb142fd64c1e3b8 Mon Sep 17 00:00:00 2001 From: xavikh Date: Tue, 10 Dec 2024 14:51:58 +0100 Subject: [PATCH] Add BaseURISet event --- src/escrow/increasing/Lock.sol | 2 ++ src/escrow/increasing/interfaces/ILock.sol | 14 +++++++++++++- 2 files changed, 15 insertions(+), 1 deletion(-) diff --git a/src/escrow/increasing/Lock.sol b/src/escrow/increasing/Lock.sol index fbf8c5a..5f23dcb 100644 --- a/src/escrow/increasing/Lock.sol +++ b/src/escrow/increasing/Lock.sol @@ -147,6 +147,8 @@ contract Lock is function setBaseURI(string memory _baseTokenURI) external auth(LOCK_ADMIN_ROLE) { baseTokenURI = _baseTokenURI; + + emit BaseURISet(baseTokenURI); } function setTokenURI(uint256 _tokenId, string memory _tokenURI) external auth(LOCK_ADMIN_ROLE) { diff --git a/src/escrow/increasing/interfaces/ILock.sol b/src/escrow/increasing/interfaces/ILock.sol index 82a22a8..90f9914 100644 --- a/src/escrow/increasing/interfaces/ILock.sol +++ b/src/escrow/increasing/interfaces/ILock.sol @@ -1,6 +1,16 @@ // SPDX-License-Identifier: MIT pragma solidity ^0.8.0; +/*/////////////////////////////////////////////////////////////// + METADATA +//////////////////////////////////////////////////////////////*/ + +interface IMetadataEvents { + /// @notice Event emmited when the base metadata URI is updated + /// @param uri New base URI + event BaseURISet(string uri); +} + /*/////////////////////////////////////////////////////////////// WHITELIST //////////////////////////////////////////////////////////////*/ @@ -21,7 +31,9 @@ interface IWhitelist is IWhitelistEvents, IWhitelistErrors { function whitelisted(address addr) external view returns (bool); } -interface ILock is IWhitelist { +interface IMetadata is IMetadataEvents {} + +interface ILock is IWhitelist, IMetadata { error OnlyEscrow(); /// @notice Address of the escrow contract that holds underyling assets