Skip to content

Commit ebc4dc9

Browse files
committed
Use to_string instead of format macro
Clippy emits: warning: useless use of `format!` As suggested, use `to_string`.
1 parent 592b479 commit ebc4dc9

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

src/lib.rs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -186,7 +186,7 @@ impl MiniscriptKey for String {
186186
type Hash = String;
187187

188188
fn to_pubkeyhash(&self) -> Self::Hash {
189-
format!("{}", &self)
189+
(&self).to_string()
190190
}
191191
}
192192

0 commit comments

Comments
 (0)