Skip to content

Commit

Permalink
runtime-sdk: approve_utx -> approve_unverified_tx
Browse files Browse the repository at this point in the history
Co-authored-by: Jernej Kos <[email protected]>
  • Loading branch information
pro-wh and kostko committed May 18, 2021
1 parent 3e0b1e5 commit 2a5a2eb
Show file tree
Hide file tree
Showing 3 changed files with 3 additions and 3 deletions.
2 changes: 1 addition & 1 deletion runtime-sdk/src/dispatcher.rs
Original file line number Diff line number Diff line change
Expand Up @@ -94,7 +94,7 @@ impl<R: Runtime> Dispatcher<R> {
cbor::from_slice(&tx).map_err(|_| modules::core::Error::MalformedTransaction)?;

// Perform any checks before signature verification.
R::Modules::approve_utx(ctx, &utx)?;
R::Modules::approve_unverified_tx(ctx, &utx)?;

// Verify transaction signatures.
// TODO: Support signature verification of the whole transaction batch.
Expand Down
2 changes: 1 addition & 1 deletion runtime-sdk/src/module.rs
Original file line number Diff line number Diff line change
Expand Up @@ -146,7 +146,7 @@ pub trait MessageHookRegistrationHandler {
pub trait AuthHandler {
/// Judge if an unverified transaction is good enough to undergo verification.
/// This takes place before even verifying signatures.
fn approve_utx(
fn approve_unverified_tx(
_ctx: &mut DispatchContext<'_>,
_utx: &UnverifiedTransaction,
) -> Result<(), modules::core::Error> {
Expand Down
2 changes: 1 addition & 1 deletion runtime-sdk/src/modules/core/mod.rs
Original file line number Diff line number Diff line change
Expand Up @@ -224,7 +224,7 @@ impl module::Module for Module {
}

impl module::AuthHandler for Module {
fn approve_utx(
fn approve_unverified_tx(
ctx: &mut DispatchContext<'_>,
utx: &UnverifiedTransaction,
) -> Result<(), Error> {
Expand Down

0 comments on commit 2a5a2eb

Please sign in to comment.