diff options
author | Matthias Beyer <matthias.beyer@ifm.com> | 2022-08-18 15:14:10 +0200 |
---|---|---|
committer | Matthias Beyer <matthias.beyer@ifm.com> | 2022-08-18 15:40:40 +0200 |
commit | c75b2e84b2af06f6c7e271cbebb09c10034d3044 (patch) | |
tree | 54b15eaa6d02e772990eb14d4991736df4ba75b6 /crates/core/c8y_smartrest | |
parent | 9677f3a0ac68ca4e55da871f39729199a2e6eae7 (diff) |
Fix clippy: Remove unnecessary .to_string()
This fixes clippy::unnecessary_to_owned
Signed-off-by: Matthias Beyer <matthias.beyer@ifm.com>
Diffstat (limited to 'crates/core/c8y_smartrest')
-rw-r--r-- | crates/core/c8y_smartrest/src/smartrest_deserializer.rs | 4 |
1 files changed, 1 insertions, 3 deletions
diff --git a/crates/core/c8y_smartrest/src/smartrest_deserializer.rs b/crates/core/c8y_smartrest/src/smartrest_deserializer.rs index 35e42b53..654e1441 100644 --- a/crates/core/c8y_smartrest/src/smartrest_deserializer.rs +++ b/crates/core/c8y_smartrest/src/smartrest_deserializer.rs @@ -176,9 +176,7 @@ where let date_string_end = &date_string.split('+').last(); date_string = match date_string_end { Some(string) if !string.contains(':') => { - date_string[0..str_size - 2].to_string() - + ":" - + &date_string[str_size - 2..str_size].to_string() + date_string[0..str_size - 2].to_string() + ":" + &date_string[str_size - 2..str_size] } _ => date_string, }; |