Skip to content

Commit

Permalink
fix file loading to prevent exceptions if user\languages doesn't exist
Browse files Browse the repository at this point in the history
  • Loading branch information
andrew-welker committed Mar 12, 2021
1 parent 441303a commit 855c01f
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion epi-utilities-i18n/I18nUtility.cs
Original file line number Diff line number Diff line change
Expand Up @@ -93,7 +93,7 @@ public int CurrentLanguageIndex

private IEnumerable<string> FindLanguagesConfigurationFiles()
{
var files = Directory.GetFiles(FileDirectoryB, FileName) ?? Directory.GetFiles(FileDirectoryA, FileName);
var files = Directory.GetFiles(Directory.Exists(FileDirectoryB) ? FileDirectoryB : FileDirectoryA, FileName);

if (files.Length != 0)
{
Expand Down

0 comments on commit 855c01f

Please sign in to comment.