Skip to content

Commit 2a6d68c

Browse files
committed
chore: added creation or recreation of the .osmosisd-local
1 parent a005066 commit 2a6d68c

File tree

1 file changed

+4
-4
lines changed

1 file changed

+4
-4
lines changed

caribic/src/start.rs

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -801,11 +801,11 @@ fn remove_previous_chain_data() -> Result<(), fs_extra::error::Error> {
801801
if let Some(home_path) = home_dir() {
802802
let osmosis_data_dir = home_path.join(".osmosisd-local");
803803
if osmosis_data_dir.exists() {
804-
remove_dir_all(osmosis_data_dir)?;
805-
Ok(())
806-
} else {
807-
Ok(())
804+
remove_dir_all(&osmosis_data_dir)?;
808805
}
806+
fs::create_dir_all(&osmosis_data_dir)
807+
.map_err(|e| fs_extra::error::Error::Io(e))?;
808+
Ok(())
809809
} else {
810810
Ok(())
811811
}

0 commit comments

Comments
 (0)