Skip to content

Commit

Permalink
Update ERC-7627: change to external
Browse files Browse the repository at this point in the history
Merged by EIP-Bot.
  • Loading branch information
chenly authored Jun 12, 2024
1 parent c23d416 commit 16be9fc
Showing 1 changed file with 3 additions and 3 deletions.
6 changes: 3 additions & 3 deletions ERCS/erc-7627.md
Original file line number Diff line number Diff line change
Expand Up @@ -111,19 +111,19 @@ contract ERC7627 {
event PublicKeyUpdated(address indexed user, bytes newPublicKey, PublicKeyAlgorithm algorithm);
// Function to register a user with their public key
function updatePublicKey(bytes calldata _publicKey, PublicKeyAlgorithm _algorithm) public {
function updatePublicKey(bytes calldata _publicKey, PublicKeyAlgorithm _algorithm) external {
pk[msg.sender].publicKey = _publicKey;
pk[msg.sender].algorithm = _algorithm;
emit PublicKeyUpdated(msg.sender, _publicKey, _algorithm);
}
// Function to send an encrypted message from one user to another
function sendMessage(address _to, bytes32 _sessionId, bytes calldata _encryptedMessage) public {
function sendMessage(address _to, bytes32 _sessionId, bytes calldata _encryptedMessage) external {
emit MessageSent(msg.sender, _to, _sessionId, _encryptedMessage);
}
// Function to retrieve a user's public key
function getUserPublicKey(address _user) public view returns (bytes memory, PublicKeyAlgorithm) {
function getUserPublicKey(address _user) external view returns (bytes memory, PublicKeyAlgorithm) {
UserInfo memory userInfo = pk[_user];
return (userInfo.publicKey, userInfo.algorithm);
}
Expand Down

0 comments on commit 16be9fc

Please sign in to comment.