fix: add aime.txt check to the importer

This commit is contained in:
2025-05-22 10:52:57 +00:00
parent 713196c9db
commit 3edefccd0b

View File

@ -43,7 +43,11 @@ impl Segatools {
if let Some(aime_path) = s.get("aimePath") {
if let Some(game_dir) = self.target.parent() {
let target = game_dir.join(aime_path);
std::fs::copy(target, config_dir.as_ref().join("aime.txt"))?;
if target.exists() {
std::fs::copy(target, config_dir.as_ref().join("aime.txt"))?;
} else {
log::warn!("aime.txt was configured in segatools.ini but it doesn't exist");
}
} else {
log::error!("profile doesn't have a game directory");
}