Skip to content

Commit b631cef

Browse files
authored
Remove unneeded .as_bytes() (#15196)
`&str` already implements `AsRef<[u8]>` changelog: none
2 parents a7c1469 + fc3d5e6 commit b631cef

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

clippy_dev/src/fmt.rs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -223,7 +223,7 @@ fn fmt_conf(check: bool) -> Result<(), Error> {
223223
if check {
224224
return Err(Error::CheckFailed);
225225
}
226-
fs::write(path, new_text.as_bytes())?;
226+
fs::write(path, new_text)?;
227227
}
228228
Ok(())
229229
}

0 commit comments

Comments
 (0)