Skip to content

Commit

Permalink
refactor: clean up document store
Browse files Browse the repository at this point in the history
(cherry picked from commit 5e1ca583660a05c4822b78ba736d484de68264aa)
  • Loading branch information
superical committed Mar 4, 2024
1 parent 44d9eae commit 72f8acc
Showing 1 changed file with 5 additions and 5 deletions.
10 changes: 5 additions & 5 deletions contracts/DocumentStore.sol
Original file line number Diff line number Diff line change
Expand Up @@ -13,7 +13,7 @@ import "./base/DocumentStoreAccessControl.sol";
* @title DocumentStore
* @notice A contract for storing and revoking documents with access control
*/
contract DocumentStore is BaseDocumentStore, DocumentStoreAccessControl {
contract DocumentStore is DocumentStoreAccessControl, BaseDocumentStore {
using MerkleProof for bytes32[];

/**
Expand All @@ -40,15 +40,15 @@ contract DocumentStore is BaseDocumentStore, DocumentStoreAccessControl {
* @param document The hash of the document to issue
*/
function issue(bytes32 documentRoot) public onlyRole(ISSUER_ROLE) onlyNotIssued(document) {
BaseDocumentStore._issue(documentRoot);
_issue(documentRoot);
}

/**
* @notice Issues multiple documents
* @param documents The hashes of the documents to issue
*/
function bulkIssue(bytes32[] memory documentRoots) public onlyRole(ISSUER_ROLE) {
BaseDocumentStore._bulkIssue(documentRoots);
_bulkIssue(documentRoots);
}

/**
Expand All @@ -57,15 +57,15 @@ contract DocumentStore is BaseDocumentStore, DocumentStoreAccessControl {
* @return A boolean indicating whether the revocation was successful
*/
function revoke(bytes32 document) public onlyRole(REVOKER_ROLE) onlyNotRevoked(document) returns (bool) {
return BaseDocumentStore._revoke(document);
return _revoke(document);
}

/**
* @notice Revokes documents in bulk
* @param documents The hashes of the documents to revoke
*/
function bulkRevoke(bytes32[] memory documents) public onlyRole(REVOKER_ROLE) {
return BaseDocumentStore._bulkRevoke(documents);
return _bulkRevoke(documents);
}

function isIssued(
Expand Down

0 comments on commit 72f8acc

Please sign in to comment.