aboutsummaryrefslogtreecommitdiff
path: root/src/client/context.rs
diff options
context:
space:
mode:
authoracdenisSK <[email protected]>2017-10-01 21:59:33 +0200
committerZeyla Hellyer <[email protected]>2017-10-09 15:46:37 -0700
commit0ce8be869eeb2eb700e22f71b2e00872cc96a500 (patch)
tree03dd981bc04ba8475333d057705820c3320e3a97 /src/client/context.rs
parentHave `ConnectionStage` derive Copy (diff)
downloadserenity-0ce8be869eeb2eb700e22f71b2e00872cc96a500.tar.xz
serenity-0ce8be869eeb2eb700e22f71b2e00872cc96a500.zip
`to_owned` -> `to_string`
Diffstat (limited to 'src/client/context.rs')
-rw-r--r--src/client/context.rs10
1 files changed, 5 insertions, 5 deletions
diff --git a/src/client/context.rs b/src/client/context.rs
index 31eeca5..2288f28 100644
--- a/src/client/context.rs
+++ b/src/client/context.rs
@@ -85,18 +85,18 @@ impl Context {
{
let cache = CACHE.read().unwrap();
- map.insert("username".to_owned(), Value::String(cache.user.name.clone()));
+ map.insert("username".to_string(), Value::String(cache.user.name.clone()));
if let Some(email) = cache.user.email.as_ref() {
- map.insert("email".to_owned(), Value::String(email.clone()));
+ map.insert("email".to_string(), Value::String(email.clone()));
}
} else {
let user = http::get_current_user()?;
- map.insert("username".to_owned(), Value::String(user.name.clone()));
+ map.insert("username".to_string(), Value::String(user.name.clone()));
if let Some(email) = user.email.as_ref() {
- map.insert("email".to_owned(), Value::String(email.clone()));
+ map.insert("email".to_string(), Value::String(email.clone()));
}
}
}
@@ -328,7 +328,7 @@ impl Context {
pub fn set_game_name(&self, game_name: &str) {
let game = Game {
kind: GameType::Playing,
- name: game_name.to_owned(),
+ name: game_name.to_string(),
url: None,
};