internal static bool FileOrDirectoryExists(string path, bool isFile) { return isFile ? File.Exists(path) : Directory.Exists(path); } }