Skip to content

Commit

Permalink
Add interface
Browse files Browse the repository at this point in the history
  • Loading branch information
miohtama committed Jan 14, 2024
1 parent 81952ef commit 21c352f
Show file tree
Hide file tree
Showing 4 changed files with 12 additions and 124 deletions.
2 changes: 1 addition & 1 deletion README.md
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
# Terms Of Service Acceptance Manager

**Note**: This project is still under initial development,
and not ready yet.
and not ready yet. It's currently a frankenstein between Foundry and Ape.

A Solidity smart contract for making sure the smart contract caller
has accepted the latest terms of service.
Expand Down
110 changes: 0 additions & 110 deletions contracts/TermsOfService.sol

This file was deleted.

1 change: 1 addition & 0 deletions contracts/TermsOfService.sol
12 changes: 0 additions & 12 deletions script/Counter.s.sol

This file was deleted.

11 changes: 10 additions & 1 deletion src/TermsOfService.sol
Original file line number Diff line number Diff line change
Expand Up @@ -8,12 +8,21 @@ import "@openzeppelin/access/Ownable.sol";
// verification of smart contract signatures
import "@openzeppelin/utils/cryptography/SignatureChecker.sol";


/**
* Minimal MVP interface
*/
interface ITermsOfService {
function canProceed() external returns (bool accepted);
function signTermsOfServiceOwn(bytes32 hash, bytes memory signature, bytes memory metadata) external;
}

/**
* Terms of service acceptance tracker
*
* Manage signatures of users of different versions of terms of service.
*/
contract TermsOfService is Ownable {
contract TermsOfService is Ownable, ITermsOfService {

using SignatureChecker for address;

Expand Down

0 comments on commit 21c352f

Please sign in to comment.