diff --git a/hardhat.config.ts b/hardhat.config.ts index 956329d..6d39baa 100644 --- a/hardhat.config.ts +++ b/hardhat.config.ts @@ -79,6 +79,13 @@ const config: HardhatUserConfig = { accounts: [process.env.PRIVATE_KEY!], saveDeployments: true, zksync: false + }, + baseTestnet: { + chainId: 84532, + url: 'https://sepolia.base.org', + accounts: [process.env.PRIVATE_KEY!], + saveDeployments: true, + zksync: false } }, etherscan: { @@ -91,7 +98,8 @@ const config: HardhatUserConfig = { sepolia: process.env.ETHERSCAN_KEY!, mainnet: process.env.ETHERSCAN_KEY!, zetachainTestnet: process.env.ZETASCAN_API_KEY!, - zetachain: process.env.ZETASCAN_API_KEY! + zetachain: process.env.ZETASCAN_API_KEY!, + baseTestnet: process.env.BASE_SEPOLIA_API_KEY! }, customChains: [ { @@ -109,6 +117,14 @@ const config: HardhatUserConfig = { apiURL: 'https://zetachain.blockscout.com/api', browserURL: 'https://zetachain.blockscout.com/' } + }, + { + network: 'baseTestnet', + chainId: 84532, + urls: { + apiURL: 'https://api-sepolia.basescan.org/api', + browserURL: 'https://sepolia.basescan.org' + } } ] }, diff --git a/src/ActuallyMetIRL.sol b/src/ActuallyMetIRL.sol index e9609bc..26e918a 100644 --- a/src/ActuallyMetIRL.sol +++ b/src/ActuallyMetIRL.sol @@ -16,7 +16,7 @@ contract ActuallyMetIRL is Ownable { error ConfirmationAddressMismatch(); - event DidMetIRL(address partyA, address partyB, uint64 attestationId); + event DidMeetIRL(address partyA, address partyB, uint64 attestationId); constructor() Ownable(_msgSender()) { } @@ -32,7 +32,7 @@ contract ActuallyMetIRL is Ownable { metIRLMapping[_msgSender()] = partyB; } - function confirmMetIRL(address partyA) external returns (uint64) { + function confirmMetIRL(address partyA, bytes memory data) external returns (uint64) { address partyB = _msgSender(); if (metIRLMapping[partyA] == partyB) { // B has confirm A's claim of having met them IRL @@ -50,10 +50,10 @@ contract ActuallyMetIRL is Ownable { dataLocation: DataLocation.ONCHAIN, revoked: false, recipients: recipients, - data: "" - }); + data: data // SignScan assumes this is from `abi.encode(...)` + }); uint64 attestationId = spInstance.attest(a, "", "", ""); - emit DidMetIRL(partyA, partyB, attestationId); + emit DidMeetIRL(partyA, partyB, attestationId); return attestationId; } else { revert ConfirmationAddressMismatch();