From 18e72f61a76c89e7c6d6de014f1fec51d7da8bd0 Mon Sep 17 00:00:00 2001 From: Vivian Plasencia Date: Thu, 12 Sep 2024 17:21:45 +0200 Subject: [PATCH 1/2] docs(contracts): improve whistleblowing contract docs --- package.json | 2 +- packages/contracts/contracts/SemaphoreWhistleblowing.sol | 4 ++-- .../contracts/interfaces/ISemaphoreWhistleblowing.sol | 4 +++- 3 files changed, 6 insertions(+), 4 deletions(-) diff --git a/package.json b/package.json index 0484296..0b7565e 100644 --- a/package.json +++ b/package.json @@ -3,7 +3,7 @@ "private": true, "packageManager": "yarn@4.1.1", "scripts": { - "build": "yarn build:libraries && yarn compile:libraries", + "build": "yarn build:libraries && yarn compile:contracts", "build:libraries": "yarn workspaces foreach -A --no-private run build", "compile:contracts": "yarn workspace contract-extensions compile", "test": "yarn test:libraries && yarn test:contracts && yarn test:circuits", diff --git a/packages/contracts/contracts/SemaphoreWhistleblowing.sol b/packages/contracts/contracts/SemaphoreWhistleblowing.sol index dd7a5ca..73de7c1 100644 --- a/packages/contracts/contracts/SemaphoreWhistleblowing.sol +++ b/packages/contracts/contracts/SemaphoreWhistleblowing.sol @@ -23,8 +23,8 @@ contract SemaphoreWhistleblowing is ISemaphoreWhistleblowing { _; } - /// @dev Initializes the Semaphore group used to verify the user's ZK proofs. - /// @param _semaphore: Semaphore group address. + /// @dev Initializes the Semaphore contract. + /// @param _semaphore: Semaphore contract address. constructor(ISemaphore _semaphore) { semaphore = _semaphore; } diff --git a/packages/contracts/contracts/interfaces/ISemaphoreWhistleblowing.sol b/packages/contracts/contracts/interfaces/ISemaphoreWhistleblowing.sol index 0f7fd67..3e02f74 100644 --- a/packages/contracts/contracts/interfaces/ISemaphoreWhistleblowing.sol +++ b/packages/contracts/contracts/interfaces/ISemaphoreWhistleblowing.sol @@ -15,7 +15,9 @@ interface ISemaphoreWhistleblowing { /// @param leak: News leak. event LeakPublished(uint256 indexed entityId, uint256 leak); - /// @dev Creates an entity and the associated Merkle tree/group. + /// @dev Creates an entity and its associated Merkle tree/group. + /// An entity represents a group of individuals, such as an organization or + /// event participants. /// @param editor: Editor of the entity. function createEntity(address editor) external; From b6ef35e6c44174124269dd31bd6df06f0cbd3360 Mon Sep 17 00:00:00 2001 From: Vivian Plasencia Date: Thu, 12 Sep 2024 17:36:53 +0200 Subject: [PATCH 2/2] Update packages/contracts/contracts/SemaphoreWhistleblowing.sol Co-authored-by: Cedoor --- packages/contracts/contracts/SemaphoreWhistleblowing.sol | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/packages/contracts/contracts/SemaphoreWhistleblowing.sol b/packages/contracts/contracts/SemaphoreWhistleblowing.sol index 73de7c1..efd5e25 100644 --- a/packages/contracts/contracts/SemaphoreWhistleblowing.sol +++ b/packages/contracts/contracts/SemaphoreWhistleblowing.sol @@ -23,7 +23,7 @@ contract SemaphoreWhistleblowing is ISemaphoreWhistleblowing { _; } - /// @dev Initializes the Semaphore contract. + /// @dev Initializes the Semaphore instance. /// @param _semaphore: Semaphore contract address. constructor(ISemaphore _semaphore) { semaphore = _semaphore;