Skip to content

Commit

Permalink
feat: [pallet-tee-worker] emit event when ops CesealBinAllowList
Browse files Browse the repository at this point in the history
  • Loading branch information
0xbillw committed May 9, 2024
1 parent ad6d21d commit 65eb951
Showing 1 changed file with 6 additions and 0 deletions.
6 changes: 6 additions & 0 deletions pallets/tee-worker/src/lib.rs
Original file line number Diff line number Diff line change
Expand Up @@ -150,6 +150,10 @@ pub mod pallet {
ValidateError,

BoundedVecError,

CesealBinAdded(H256),

CesealBinRemoved(H256),
}

#[pallet::error]
Expand Down Expand Up @@ -686,6 +690,7 @@ pub mod pallet {
let now = frame_system::Pallet::<T>::block_number();
CesealBinAddedAt::<T>::insert(&ceseal_hash, now);

Self::deposit_event(Event::<T>::CesealBinAdded(ceseal_hash));
Ok(())
}

Expand All @@ -705,6 +710,7 @@ pub mod pallet {

CesealBinAddedAt::<T>::remove(&ceseal_hash);

Self::deposit_event(Event::<T>::CesealBinRemoved(ceseal_hash));
Ok(())
}

Expand Down

0 comments on commit 65eb951

Please sign in to comment.