Core/Misc: Changed GetLocaleByName to return invalid value on invalid input instead of LOCALE_enUS
Port From (https://github.com/TrinityCore/TrinityCore/commit/79cd94d26df33a332586b2aa72a99b123199c88f)
This commit is contained in:
@@ -370,6 +370,11 @@ namespace Framework.Constants
|
||||
}
|
||||
return SkillType.None;
|
||||
}
|
||||
|
||||
public static bool IsValidLocale(Locale locale)
|
||||
{
|
||||
return locale < Locale.Total && locale != Locale.None;
|
||||
}
|
||||
}
|
||||
|
||||
public enum Locale
|
||||
|
||||
Reference in New Issue
Block a user