@@ -237,7 +237,7 @@ impl<B, D> Wallet<B, D>
237237where
238238 D : BatchDatabase ,
239239{
240- // Return a newly derived address using the external descriptor
240+ // Return a newly derived address for the specified `keychain`.
241241 fn get_new_address ( & self , keychain : KeychainKind ) -> Result < AddressInfo , Error > {
242242 let incremented_index = self . fetch_and_increment_index ( keychain) ?;
243243
@@ -254,8 +254,8 @@ where
254254 . map_err ( |_| Error :: ScriptDoesntHaveAddressForm )
255255 }
256256
257- // Return the the last previously derived address if it has not been used in a received
258- // transaction. Otherwise return a new address using [`Wallet::get_new_address`].
257+ // Return the the last previously derived address for `keychain` if it has not been used in a
258+ // received transaction. Otherwise return a new address using [`Wallet::get_new_address`].
259259 fn get_unused_address ( & self , keychain : KeychainKind ) -> Result < AddressInfo , Error > {
260260 let current_index = self . fetch_index ( keychain) ?;
261261
@@ -285,7 +285,7 @@ where
285285 }
286286 }
287287
288- // Return derived address for the external descriptor at a specific index
288+ // Return derived address for the descriptor of given [`KeychainKind`] at a specific index
289289 fn peek_address ( & self , index : u32 , keychain : KeychainKind ) -> Result < AddressInfo , Error > {
290290 self . get_descriptor_for_keychain ( keychain)
291291 . as_derived ( index, & self . secp )
@@ -294,7 +294,7 @@ where
294294 . map_err ( |_| Error :: ScriptDoesntHaveAddressForm )
295295 }
296296
297- // Return derived address for the external descriptor at a specific index and reset current
297+ // Return derived address for `keychain` at a specific index and reset current
298298 // address index
299299 fn reset_address ( & self , index : u32 , keychain : KeychainKind ) -> Result < AddressInfo , Error > {
300300 self . set_index ( keychain, index) ?;
0 commit comments