Skip to content

Commit

Permalink
Document LocalKeystore insert method (paritytech#3336)
Browse files Browse the repository at this point in the history
Refer to paritytech#3320
discussion
  • Loading branch information
davxy committed Feb 16, 2024
1 parent 0d311fd commit 2b8098a
Showing 1 changed file with 7 additions and 0 deletions.
7 changes: 7 additions & 0 deletions substrate/client/keystore/src/local.rs
Original file line number Diff line number Diff line change
Expand Up @@ -143,6 +143,13 @@ impl LocalKeystore {
}

impl Keystore for LocalKeystore {
/// Insert a new secret key.
///
/// WARNING: if the secret keypair has been manually generated using a password
/// (e.g. using methods such as [`sp_core::crypto::Pair::from_phrase`]) then such
/// a password must match the one used to open the keystore via [`LocalKeystore::open`].
/// If the passwords doesn't match then the inserted key ends up being unusable under
/// the current keystore instance.
fn insert(
&self,
key_type: KeyTypeId,
Expand Down

0 comments on commit 2b8098a

Please sign in to comment.