Skip to content

Simplify PathBuf setting #37

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

Merged
merged 2 commits into from
Feb 24, 2023
Merged

Conversation

lonesometraveler
Copy link
Contributor

No description provided.

@hacknus
Copy link
Owner

hacknus commented Feb 24, 2023

we should only call

match self.save_tx.send(self.picked_path.clone()) {
    Ok(_) => {}
    Err(err) => {
        print_to_console(
            &self.print_lock,
            Print::Error(format!(
                "save_tx thread send failed: {:?}",
                err
            )),
        );
    }
}

if rfd::FileDialog::new().save_file() is ok and does not fail, otherwise the other thread will try to save to the default path, which does not exist.

@lonesometraveler
Copy link
Contributor Author

OK. I have just updated the code.

@hacknus hacknus merged commit 03527dc into hacknus:main Feb 24, 2023
@lonesometraveler lonesometraveler deleted the refactor_gui_4 branch February 28, 2023 11:56
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants