Skip to content

Commit

Permalink
Make prevOwner definition more detailed
Browse files Browse the repository at this point in the history
  • Loading branch information
louis-md committed Nov 20, 2024
1 parent df3ce91 commit da6629f
Show file tree
Hide file tree
Showing 2 changed files with 18 additions and 3 deletions.
13 changes: 11 additions & 2 deletions pages/reference-smart-account/owners/removeOwner.mdx
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,9 @@ import ChangedThreshold from '../../../components/Events/mdx/ChangedThreshold.md

Removes the owner `owner` from the Safe and updates the threshold to `_threshold`.

<Callout type='warning'>This action can only be done via a Safe transaction.</Callout>
<Callout type='warning'>
This action can only be done via a Safe transaction.
</Callout>

## Usage

Expand All @@ -35,6 +37,7 @@ Removes the owner `owner` from the Safe and updates the threshold to `_threshold
}
}
```

</Tabs.Tab>
</Tabs>

Expand All @@ -46,7 +49,13 @@ Removes the owner `owner` from the Safe and updates the threshold to `_threshold

- **Type:** `address`

Current owner address.
Owner address that is pointing to the owner to be removed in the contract [linked list](https://github.com/safe-global/safe-smart-account/blob/7f79aaf05c33df71d9cb687f0bc8a73fa39d25d5/contracts/base/OwnerManager.sol#L19).

<Callout type='info'>
A linked list is a data structure that allows efficient insertion and removal
of elements in a list. Each element in it will point to the next one. In Safe
contracts, the owners are stored in a linked list.
</Callout>

```solidity focus=2
(ISafe safe).removeOwner(
Expand Down
8 changes: 7 additions & 1 deletion pages/reference-smart-account/owners/swapOwner.mdx
Original file line number Diff line number Diff line change
Expand Up @@ -47,7 +47,13 @@ Replaces the owner `oldOwner` in the Safe with `newOwner`.

- **Type:** `address`

Owner that points to the owner to be replaced in the linked list.
Owner address that is pointing to the owner to be removed in the contract [linked list](https://github.com/safe-global/safe-smart-account/blob/7f79aaf05c33df71d9cb687f0bc8a73fa39d25d5/contracts/base/OwnerManager.sol#L19).

<Callout type='info'>
A linked list is a data structure that allows efficient insertion and removal
of elements in a list. Each element in it will point to the next one. In Safe
contracts, the owners are stored in a linked list.
</Callout>

```solidity focus=2
(ISafe safe).swapOwner(
Expand Down

0 comments on commit da6629f

Please sign in to comment.