We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
1 parent 527fb04 commit 689ac48Copy full SHA for 689ac48
1 file changed
CountryHelper.cs
@@ -69,17 +69,8 @@ public List<Regions> GetRegionByCountryCode(string ShortCode)
69
/// <summary>
70
/// Gets the list of all countries in the worlld
71
/// </summary>
72
- /// <returns>List<String> countries</returns>
73
- public List<String> GetCountries()
74
- {
75
- List<String> data = new List<string>();
76
- var countries = _Countries.Select(c => c.CountryName).ToList();
77
- foreach (var item in countries)
78
79
- data.Add(item);
80
- }
81
- return countries;
82
+ /// <returns>IEnumerable<string> countries</returns>
+ public IEnumerable<string> GetCountries() => _Countries.Select(c => c.CountryName);
83
84
}
85
0 commit comments