From 0ce8be869eeb2eb700e22f71b2e00872cc96a500 Mon Sep 17 00:00:00 2001 From: acdenisSK Date: Sun, 1 Oct 2017 21:59:33 +0200 Subject: `to_owned` -> `to_string` --- src/utils/colour.rs | 2 +- src/utils/message_builder.rs | 4 ++-- src/utils/mod.rs | 8 ++++---- 3 files changed, 7 insertions(+), 7 deletions(-) (limited to 'src/utils') diff --git a/src/utils/colour.rs b/src/utils/colour.rs index a263019..72df2e9 100644 --- a/src/utils/colour.rs +++ b/src/utils/colour.rs @@ -37,7 +37,7 @@ macro_rules! colour { /// # id: RoleId(1), /// # managed: false, /// # mentionable: false, -/// # name: "test".to_owned(), +/// # name: "test".to_string(), /// # permissions: permissions::PRESET_GENERAL, /// # position: 7, /// # }; diff --git a/src/utils/message_builder.rs b/src/utils/message_builder.rs index 2f714ec..f58c0b3 100644 --- a/src/utils/message_builder.rs +++ b/src/utils/message_builder.rs @@ -19,7 +19,7 @@ use model::{ChannelId, Emoji, Mentionable, RoleId, UserId}; /// # let user = UserId(1); /// # let emoji = Emoji { /// # id: EmojiId(2), -/// # name: "test".to_owned(), +/// # name: "test".to_string(), /// # managed: false, /// # require_colons: true, /// # roles: vec![], @@ -144,7 +144,7 @@ impl MessageBuilder { /// let emoji = Emoji { /// id: EmojiId(302516740095606785), /// managed: true, - /// name: "smugAnimeFace".to_owned(), + /// name: "smugAnimeFace".to_string(), /// require_colons: true, /// roles: vec![], /// }; diff --git a/src/utils/mod.rs b/src/utils/mod.rs index d81b0f9..4b36b73 100644 --- a/src/utils/mod.rs +++ b/src/utils/mod.rs @@ -259,7 +259,7 @@ pub fn parse_channel(mention: &str) -> Option { /// /// let expected = EmojiIdentifier { /// id: EmojiId(302516740095606785), -/// name: "smugAnimeFace".to_owned(), +/// name: "smugAnimeFace".to_string(), /// }; /// /// assert_eq!(parse_emoji("<:smugAnimeFace:302516740095606785>").unwrap(), expected); @@ -359,8 +359,8 @@ pub fn read_image>(path: P) -> Result { /// /// let command = r#""this is the first" "this is the second""#; /// let expected = vec![ -/// "this is the first".to_owned(), -/// "this is the second".to_owned() +/// "this is the first".to_string(), +/// "this is the second".to_string() /// ]; /// /// assert_eq!(parse_quotes(command), expected); @@ -371,7 +371,7 @@ pub fn read_image>(path: P) -> Result { /// /// let command = r#""this is a quoted command that doesn't have an ending quotation"#; /// let expected = vec![ -/// "this is a quoted command that doesn't have an ending quotation".to_owned(), +/// "this is a quoted command that doesn't have an ending quotation".to_string(), /// ]; /// /// assert_eq!(parse_quotes(command), expected); -- cgit v1.2.3