From 6fd88e8cf46c4a5e9179b1aa031813f9324110cc Mon Sep 17 00:00:00 2001 From: 0xbeny Date: Fri, 31 May 2024 11:38:22 +0400 Subject: [PATCH] updated DPF-01 --- packages/contracts/src/DaofinPlugin.sol | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/packages/contracts/src/DaofinPlugin.sol b/packages/contracts/src/DaofinPlugin.sol index 776b974..83546ac 100644 --- a/packages/contracts/src/DaofinPlugin.sol +++ b/packages/contracts/src/DaofinPlugin.sol @@ -630,10 +630,10 @@ contract DaofinPlugin is BaseDaofinPlugin { } function editProposalMetadata(uint256 _proposalId, bytes calldata _metadata) external { - (bool open, bool executed, address proposer, ) = getProposal(_proposalId); + (, bool executed, address proposer, ) = getProposal(_proposalId); // Proposal must be before election its attached election period. - if (open || executed) revert InValidTime(); + if (block.timestamp > _proposals[_proposalId].startDate || executed) revert InValidTime(); // Only proposer address is able to modify metadata. if (proposer != _msgSender()) revert InValidAddress();