mirror of
https://github.com/greenshot/greenshot
synced 2025-07-16 10:03:44 -07:00
BUG-2095: Improved the validity check of the OutputFileAsFullpath setting, this should prevent a reset if only the file is not available.
This commit is contained in:
parent
25d9c17bed
commit
c77e77578d
2 changed files with 6 additions and 3 deletions
|
@ -69,7 +69,8 @@ namespace GreenshotPlugin.Controls {
|
|||
string initialDirectory = null;
|
||||
try {
|
||||
// Added for BUG-1992, reset the OutputFilePath / OutputFileAsFullpath if they don't exist (e.g. the configuration is used on a different PC)
|
||||
if (!File.Exists(conf.OutputFileAsFullpath))
|
||||
var outputFilePath = Path.GetDirectoryName(conf.OutputFileAsFullpath);
|
||||
if (outputFilePath == null || (!File.Exists(conf.OutputFileAsFullpath) && !Directory.Exists(outputFilePath)))
|
||||
{
|
||||
conf.OutputFileAsFullpath = conf.GetDefault(nameof(conf.OutputFileAsFullpath)) as string;
|
||||
}
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue