Skip to content

Commit

Permalink
Merge #4566
Browse files Browse the repository at this point in the history
4566: Change PublicKey on Bid r=EdHastingsCasperAssociation a=wojcik91

Implements casper-network/ceps#91

Co-authored-by: Maciej Wójcik <[email protected]>
  • Loading branch information
casperlabs-bors-ng[bot] and Maciej Wójcik authored Apr 23, 2024
2 parents a528ab8 + 2e34cee commit 8972f3d
Show file tree
Hide file tree
Showing 35 changed files with 1,400 additions and 86 deletions.
4 changes: 4 additions & 0 deletions .gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -161,3 +161,7 @@ notes
.lh/*

*.patch

# direnv-related files
.envrc
.direnv/
8 changes: 8 additions & 0 deletions Cargo.lock

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

14 changes: 14 additions & 0 deletions execution_engine/src/runtime/mod.rs
Original file line number Diff line number Diff line change
Expand Up @@ -985,6 +985,20 @@ where
CLValue::from_t(()).map_err(Self::reverter)
})(),

auction::METHOD_CHANGE_BID_PUBLIC_KEY => (|| {
runtime.charge_system_contract_call(auction_costs.change_bid_public_key)?;

let public_key = Self::get_named_argument(runtime_args, auction::ARG_PUBLIC_KEY)?;
let new_public_key =
Self::get_named_argument(runtime_args, auction::ARG_NEW_PUBLIC_KEY)?;

runtime
.change_bid_public_key(public_key, new_public_key)
.map_err(Self::reverter)?;

CLValue::from_t(()).map_err(Self::reverter)
})(),

_ => CLValue::from_t(()).map_err(Self::reverter),
};

Expand Down
Loading

0 comments on commit 8972f3d

Please sign in to comment.