/// <summary> /// Get A Setting /// </summary> /// <param name="settingName"></param> /// <returns></returns> public static Setting Get(string settingName) { if (!IsInizialized) { throw new Exception(_ErrorMessage); } //Check arguments if (String.IsNullOrWhiteSpace(settingName)) { throw new ArgumentNullException(nameof(settingName)); } //If the setting is in the Main Settings Collection return it, else find in Extra Settings Collection var res = SettingsList.Where(s => s.Name == settingName).FirstOrDefault(); if (res != null) { return(res); } return(SettingsList.Where(s => s.Name == settingName).FirstOrDefault()); }