We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
1 parent 4ed5fba commit 90756feCopy full SHA for 90756fe
1 file changed
src/core/scriptslog.rs
@@ -60,14 +60,12 @@ fn scriptslog_file() -> Result<File, String> {
60
let mut docs = None;
61
if let Some(ud) = UserDirs::new() {
62
if let Some(path) = ud.document_dir() {
63
- if let Some(s) = path.to_str() {
64
- docs = Some(s.to_owned());
65
- }
+ docs = Some(path.to_owned());
66
}
67
68
69
if let Some(docs) = docs {
70
- let scriptslog_path = Path::new(&docs).join(Path::new("The Witcher 3").join(constants::SCRIPTSLOG_FILE_NAME));
+ let scriptslog_path = docs.join(Path::new("The Witcher 3").join(constants::SCRIPTSLOG_FILE_NAME));
71
72
let file = OpenOptions::new()
73
.read(true)
0 commit comments