Skip to content

Commit

Permalink
change function name to _preslashing
Browse files Browse the repository at this point in the history
  • Loading branch information
supernovahs committed Feb 20, 2025
1 parent a818e54 commit f089113
Show file tree
Hide file tree
Showing 2 changed files with 5 additions and 5 deletions.
4 changes: 2 additions & 2 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
Expand Up @@ -112,7 +112,7 @@ Those changes in added, changed or breaking changes, should include usage exampl
el_chain_writer.set_signer(PRIVATE_KEY_STRING);
```

* Added additional method `register_as_operator_m2` in `ELChainWriter` in [#366](https://github.com/Layr-Labs/eigensdk-rs/pull/366).This method is to be used for pre operator-sets.
* Added additional method `register_as_operator_preslashing` in `ELChainWriter` in [#366](https://github.com/Layr-Labs/eigensdk-rs/pull/366).This method is to be used for pre-slashing.

```rust
let operator = Operator {
Expand All @@ -124,7 +124,7 @@ Those changes in added, changed or breaking changes, should include usage exampl
staker_opt_out_window_blocks: Some(0u32),
};
el_chain_writer
.register_as_operator_m2(operator)
.register_as_operator_preslashing(operator)
.await
.unwrap();
```
Expand Down
6 changes: 3 additions & 3 deletions crates/chainio/clients/elcontracts/src/writer.rs
Original file line number Diff line number Diff line change
Expand Up @@ -84,7 +84,7 @@ impl ELChainWriter {
self.signer = signer;
}

pub async fn register_as_operator_m2(
pub async fn register_as_operator_preslashing(
&self,
operator: Operator,
) -> Result<TxHash, ElContractsError> {
Expand Down Expand Up @@ -970,7 +970,7 @@ mod tests {
}

#[tokio::test]
async fn test_register_operator_m2() {
async fn test_register_operator_preslashing() {
let (_container, http_endpoint, _ws_endpoint) = start_m2_anvil_container().await;
let el_chain_reader = build_el_chain_reader(http_endpoint.clone()).await;
let el_chain_writer =
Expand All @@ -985,7 +985,7 @@ mod tests {
staker_opt_out_window_blocks: Some(0u32),
};
el_chain_writer
.register_as_operator_m2(operator)
.register_as_operator_preslashing(operator)
.await
.unwrap();

Expand Down

0 comments on commit f089113

Please sign in to comment.