fix #37 - check dir exists before trying to open it

This commit is contained in:
Adam 2021-07-11 13:01:28 +10:00
parent 25f901bb7c
commit 9decf26ab6

View file

@ -1,5 +1,6 @@
using System;
using System.Diagnostics;
using System.IO;
using System.Text.RegularExpressions;
using Dalamud.Plugin;
using ImGuiNET;
@ -58,6 +59,11 @@ namespace Penumbra.UI
{
if( ImGui.Button( LabelOpenFolder ) )
{
if( !Directory.Exists( _config.ModDirectory ) )
{
return;
}
Process.Start( _config.ModDirectory );
}
}