Skip to content

Commit

Permalink
Add docs for extend_ttl_for_{code,contract_instance} (#1268)
Browse files Browse the repository at this point in the history
### What

[TODO: Short statement about what is changing.]

### Why

[TODO: Why this change is being made. Include any context required to
understand the why.]

### Known limitations

[TODO or N/A]
  • Loading branch information
jayz22 authored May 2, 2024
1 parent 2325682 commit a2991e9
Showing 1 changed file with 6 additions and 0 deletions.
6 changes: 6 additions & 0 deletions soroban-sdk/src/deploy.rs
Original file line number Diff line number Diff line change
Expand Up @@ -160,6 +160,9 @@ impl Deployer {
.unwrap_infallible();
}

/// Extend the TTL of the contract instance.
///
/// Same as [`extend_ttl`](Self::extend_ttl) but only for contract instance.
pub fn extend_ttl_for_contract_instance(
&self,
contract_address: Address,
Expand All @@ -175,6 +178,9 @@ impl Deployer {
.unwrap_infallible();
}

/// Extend the TTL of the contract code.
///
/// Same as [`extend_ttl`](Self::extend_ttl) but only for contract code.
pub fn extend_ttl_for_code(&self, contract_address: Address, threshold: u32, extend_to: u32) {
self.env
.extend_contract_code_ttl(
Expand Down

0 comments on commit a2991e9

Please sign in to comment.