Skip to content

Commit 5d1492d

Browse files
simlecodernbguyseanchen1991
authored
chore: fix grammar in doc comments (#1222)
* chore: Remove duplicate words * bunch of grammar fixes --------- Co-authored-by: Ranadeep Biswas <[email protected]> Co-authored-by: Sean Chen <[email protected]>
1 parent 5873500 commit 5d1492d

File tree

67 files changed

+134
-134
lines changed

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

67 files changed

+134
-134
lines changed

ibc-apps/ics20-transfer/src/context.rs

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -21,7 +21,7 @@ pub trait TokenTransferValidationContext {
2121

2222
/// Validates that the tokens can be escrowed successfully.
2323
///
24-
/// `memo` field allows to incorporate additional contextual details in the
24+
/// `memo` field allows incorporating additional contextual details in the
2525
/// escrow validation.
2626
fn escrow_coins_validate(
2727
&self,
@@ -50,7 +50,7 @@ pub trait TokenTransferValidationContext {
5050

5151
/// Validates the sender account and the coin input before burning.
5252
///
53-
/// `memo` field allows to incorporate additional contextual details in the
53+
/// `memo` field allows incorporating additional contextual details in the
5454
/// burn validation.
5555
fn burn_coins_validate(
5656
&self,
@@ -70,7 +70,7 @@ pub trait TokenTransferValidationContext {
7070
pub trait TokenTransferExecutionContext: TokenTransferValidationContext {
7171
/// Executes the escrow of the tokens in a user account.
7272
///
73-
/// `memo` field allows to incorporate additional contextual details in the
73+
/// `memo` field allows incorporating additional contextual details in the
7474
/// escrow execution.
7575
fn escrow_coins_execute(
7676
&mut self,
@@ -99,7 +99,7 @@ pub trait TokenTransferExecutionContext: TokenTransferValidationContext {
9999

100100
/// Executes burning of the tokens in a user account.
101101
///
102-
/// `memo` field allows to incorporate additional contextual details in the
102+
/// `memo` field allows incorporating additional contextual details in the
103103
/// burn execution.
104104
fn burn_coins_execute(
105105
&mut self,

ibc-apps/ics20-transfer/types/src/denom.rs

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -90,7 +90,7 @@ impl TracePrefix {
9090
/// it returns a tuple of the removed [`TracePrefix`] and the substring after the prefix.
9191
///
9292
/// If the substring is empty, it returns `None`.
93-
/// Otherwise the substring starts with `/`. In that case,
93+
/// Otherwise, the substring starts with `/`. In that case,
9494
/// the leading `/` is stripped and returned.
9595
///
9696
/// If the string does not start with a [`TracePrefix`], this method returns `None`.
@@ -174,7 +174,7 @@ impl TracePath {
174174
/// [`TracePath`] and the substring after the [`TracePath`].
175175
///
176176
/// If the substring is empty, it returns `None`.
177-
/// Otherwise the substring starts with `/`. In that case,
177+
/// Otherwise, the substring starts with `/`. In that case,
178178
/// the leading `/` is stripped and returned.
179179
///
180180
/// If the string does not contain any [`TracePrefix`], it returns the original string.
@@ -273,7 +273,7 @@ impl PrefixedDenom {
273273
}
274274
}
275275

276-
/// Returns true if the denomination originally came from the sender chain and
276+
/// Returns true if the denomination originally came from the sender chain, and
277277
/// false otherwise.
278278
///
279279
/// Note: It is better to think of the "source" chain as the chain that
@@ -305,7 +305,7 @@ pub fn is_sender_chain_source(
305305
!is_receiver_chain_source(source_port, source_channel, denom)
306306
}
307307

308-
/// Returns true if the denomination originally came from the receiving chain and false otherwise.
308+
/// Returns true if the denomination originally came from the receiving chain, and false otherwise.
309309
pub fn is_receiver_chain_source(
310310
source_port: PortId,
311311
source_channel: ChannelId,

ibc-apps/ics20-transfer/types/src/error.rs

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -43,7 +43,7 @@ pub enum TokenTransferError {
4343
MalformedTrace(String),
4444
/// trace length must be even but got: `{len}`
4545
InvalidTraceLength { len: u64 },
46-
/// invalid amount error: `{0}`
46+
/// invalid amount: `{0}`
4747
InvalidAmount(FromDecStrErr),
4848
/// invalid token
4949
InvalidToken,
@@ -75,7 +75,7 @@ pub enum TokenTransferError {
7575
UnknownMsgType { msg_type: String },
7676
/// invalid coin string: `{coin}`
7777
InvalidCoin { coin: String },
78-
/// decoding raw bytes as UTF8 string error: `{0}`
78+
/// decoding raw bytes as UTF-8 string error: `{0}`
7979
Utf8Decode(Utf8Error),
8080
/// other error: `{0}`
8181
Other(String),

ibc-apps/ics20-transfer/types/src/lib.rs

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -46,8 +46,8 @@ pub const PORT_ID_STR: &str = "transfer";
4646
/// ICS20 application current version.
4747
pub const VERSION: &str = "ics20-1";
4848

49-
/// The successful string used for creating an acknowledgement status,
50-
/// equivalent to `base64::encode(0x01)`.
49+
/// The successful string, used for creating an acknowledgement status.
50+
/// It is equivalent to `base64::encode(0x01)`.
5151
pub const ACK_SUCCESS_B64: &str = "AQ==";
5252

5353
use ibc_core::channel::types::acknowledgement::StatusValue;

ibc-apps/ics721-nft-transfer/src/context.rs

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -67,7 +67,7 @@ pub trait NftTransferValidationContext {
6767
/// Validates that the tokens can be escrowed successfully.
6868
///
6969
/// The owner of the NFT should be checked in this validation.
70-
/// `memo` field allows to incorporate additional contextual details in the
70+
/// `memo` field allows incorporating additional contextual details in the
7171
/// escrow validation.
7272
fn escrow_nft_validate(
7373
&self,
@@ -109,7 +109,7 @@ pub trait NftTransferValidationContext {
109109
/// Validates the sender account and the coin input before burning.
110110
///
111111
/// The owner of the NFT should be checked in this validation.
112-
/// `memo` field allows to incorporate additional contextual details in the
112+
/// `memo` field allows incorporating additional contextual details in the
113113
/// burn validation.
114114
fn burn_nft_validate(
115115
&self,
@@ -153,7 +153,7 @@ pub trait NftTransferExecutionContext: NftTransferValidationContext {
153153

154154
/// Executes the escrow of the NFT in a user account.
155155
///
156-
/// `memo` field allows to incorporate additional contextual details in the
156+
/// `memo` field allows incorporating additional contextual details in the
157157
/// escrow execution.
158158
fn escrow_nft_execute(
159159
&mut self,
@@ -187,7 +187,7 @@ pub trait NftTransferExecutionContext: NftTransferValidationContext {
187187

188188
/// Executes burning of the NFT in a user account.
189189
///
190-
/// `memo` field allows to incorporate additional contextual details in the
190+
/// `memo` field allows incorporating additional contextual details in the
191191
/// burn execution.
192192
fn burn_nft_execute(
193193
&mut self,

ibc-apps/ics721-nft-transfer/types/src/class.rs

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -92,7 +92,7 @@ impl PrefixedClassId {
9292
}
9393
}
9494

95-
/// Returns true if the class ID originally came from the sender chain and false otherwise.
95+
/// Returns true if the class ID originally came from the sender chain, and false otherwise.
9696
pub fn is_sender_chain_source(
9797
source_port: PortId,
9898
source_channel: ChannelId,
@@ -101,7 +101,7 @@ pub fn is_sender_chain_source(
101101
!is_receiver_chain_source(source_port, source_channel, class_id)
102102
}
103103

104-
/// Returns true if the class ID originally came from the receiving chain and false otherwise.
104+
/// Returns true if the class ID originally came from the receiving chain, and false otherwise.
105105
pub fn is_receiver_chain_source(
106106
source_port: PortId,
107107
source_channel: ChannelId,

ibc-apps/ics721-nft-transfer/types/src/error.rs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -86,7 +86,7 @@ pub enum NftTransferError {
8686
DecodeRawMsg { reason: String },
8787
/// unknown msg type: `{msg_type}`
8888
UnknownMsgType { msg_type: String },
89-
/// decoding raw bytes as UTF8 string error: `{0}`
89+
/// decoding raw bytes as UTF-8 string error: `{0}`
9090
Utf8Decode(Utf8Error),
9191
/// other error: `{0}`
9292
Other(String),

ibc-apps/ics721-nft-transfer/types/src/lib.rs

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -45,8 +45,8 @@ pub const PORT_ID_STR: &str = "nft-transfer";
4545
/// ICS-721 application current version.
4646
pub const VERSION: &str = "ics721-1";
4747

48-
/// The successful string used for creating an acknowledgement status,
49-
/// equivalent to `base64::encode(0x01)`.
48+
/// The successful string, used for creating an acknowledgement status.
49+
/// It is equivalent to `base64::encode(0x01)`.
5050
pub const ACK_SUCCESS_B64: &str = "AQ==";
5151

5252
use ibc_core::channel::types::acknowledgement::StatusValue;

ibc-clients/cw-context/src/context/mod.rs

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -23,16 +23,16 @@ use crate::utils::AnyCodec;
2323

2424
type Checksum = Vec<u8>;
2525

26-
/// - [`Height`] can not be used directly as keys in the map,
26+
/// - [`Height`] cannot be used directly as keys in the map,
2727
/// as it doesn't implement some cw_storage specific traits.
2828
/// - Only a sorted set is needed. So the value type is set to
2929
/// [`Empty`] following
3030
/// ([cosmwasm-book](https://book.cosmwasm.com/cross-contract/map-storage.html#maps-as-sets)).
3131
pub const CONSENSUS_STATE_HEIGHT_MAP: Map<'_, (u64, u64), Empty> =
3232
Map::new(ITERATE_CONSENSUS_STATE_PREFIX);
3333

34-
/// Context is a wrapper around the deps and env that gives access to the
35-
/// methods under the ibc-rs Validation and Execution traits.
34+
/// Context is a wrapper around the deps and env that provides access
35+
/// to the methods under the ibc-rs Validation and Execution traits.
3636
pub struct Context<'a, C: ClientType<'a>>
3737
where
3838
<C::ClientState as TryFrom<Any>>::Error: Into<ClientError>,

ibc-clients/cw-context/src/lib.rs

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,10 +1,10 @@
11
//! Contains types and implementations that are needed to integrate a light
2-
//! client, built using ibc-rs, into CosmWasm contract. This crate functions as
2+
//! client, built using ibc-rs, into a CosmWasm contract. This crate functions as
33
//! a library, allowing users to import the ready-made `Context` object that is
44
//! generic across light clients, introduce their concrete client type and
55
//! integrate their assembled context into the CosmWasm contract's entrypoint.
66
//! NOTE: To utilize the CosmWasm contract developed using this library, hosting
7-
//! environments must support CosmWasm module and be using one the versions of
7+
//! environments must support the CosmWasm module and be using one of the versions of
88
//! `ibc-go` that supports the `08-wasm` proxy light client.
99
1010
#![cfg_attr(not(test), deny(clippy::unwrap_used))]

0 commit comments

Comments
 (0)