feat(evm): add wallet_access_id to grant deletion requests and revocation logic

This commit is contained in:
CleverWild
2026-06-09 19:16:21 +02:00
committed by Skipper
parent 3302bb8995
commit bb28d311a1
5 changed files with 19 additions and 6 deletions

View File

@@ -158,9 +158,13 @@ impl EvmActor {
}
#[message]
pub async fn useragent_delete_grant(&mut self, grant_id: i32) -> Result<(), Error> {
pub async fn useragent_delete_grant(
&mut self,
grant_id: i32,
wallet_access_id: i32,
) -> Result<(), Error> {
self.engine
.revoke_grant(grant_id)
.revoke_grant(grant_id, wallet_access_id)
.await
.map_err(Error::from)
}

View File

@@ -360,12 +360,13 @@ impl UserAgentSession {
pub(crate) async fn handle_grant_delete(
&mut self,
grant_id: i32,
wallet_access_id: i32,
) -> Result<(), GrantMutationError> {
// match self
// .props
// .actors
// .evm
// .ask(UseragentDeleteGrant { grant_id })
// .ask(UseragentDeleteGrant { grant_id, wallet_access_id })
// .await
// {
// Ok(()) => Ok(()),
@@ -374,7 +375,7 @@ impl UserAgentSession {
// Err(GrantMutationError::Internal)
// }
// }
let _ = grant_id;
let _ = (grant_id, wallet_access_id);
todo!()
}