Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

fix: create configuration directory correctly #225

Merged
merged 1 commit into from
Feb 6, 2024
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
1 change: 1 addition & 0 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
Expand Up @@ -16,6 +16,7 @@ Fixed:

- Accept '*' as a legal special symbol for usernames
- Accept '/' in usernames, ensuring correct parsing for bouncers using the nick/server convention
- Create the configuration directory correctly, if it does not exist yet.


# 2023.5 (2023-11-12)
Expand Down
4 changes: 2 additions & 2 deletions data/src/config.rs
Original file line number Diff line number Diff line change
Expand Up @@ -62,7 +62,7 @@ impl Config {
let dir = environment::config_dir();

if !dir.exists() {
std::fs::create_dir(dir.as_path())
std::fs::create_dir_all(dir.as_path())
.expect("expected permissions to create config folder");
}

Expand All @@ -73,7 +73,7 @@ impl Config {
let dir = Self::config_dir().join("themes");

if !dir.exists() {
std::fs::create_dir(dir.as_path())
std::fs::create_dir_all(dir.as_path())
.expect("expected permissions to create themes folder");
}

Expand Down
Loading