Skip to content

Commit 020e6a2

Browse files
waywardmonkeysalerque
authored andcommitted
refactor: Fix suspicious to_owned on Cow
1 parent ca0a44a commit 020e6a2

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

fluent-bundle/tests/function.rs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -32,7 +32,7 @@ liked-count2 = { NUMBER($num) ->
3232
FluentValue::Number(num)
3333
}
3434
Some(FluentValue::String(s)) => {
35-
let num: f64 = if let Ok(n) = s.to_owned().parse() {
35+
let num: f64 = if let Ok(n) = s.clone().parse() {
3636
n
3737
} else {
3838
return FluentValue::Error;

0 commit comments

Comments
 (0)