mirror of
https://github.com/CyberL1/Minecraft-Realms-Emulator.git
synced 2024-11-21 21:58:21 -05:00
remove useless function
This commit is contained in:
parent
5a39a7d471
commit
412e842905
@ -33,7 +33,7 @@ namespace Minecraft_Realms_Emulator.Helpers
|
||||
|
||||
public Configuration? GetSetting(string key)
|
||||
{
|
||||
var setting = Db.Configuration.Find(FirstCharToLowerCase(key));
|
||||
var setting = Db.Configuration.Find(key);
|
||||
|
||||
if (setting == null) return null;
|
||||
|
||||
@ -43,13 +43,5 @@ namespace Minecraft_Realms_Emulator.Helpers
|
||||
Value = JsonConvert.DeserializeObject(setting.Value)
|
||||
};
|
||||
}
|
||||
|
||||
private static string FirstCharToLowerCase(string str)
|
||||
{
|
||||
if (!string.IsNullOrEmpty(str) && char.IsUpper(str[0]))
|
||||
return str.Length == 1 ? char.ToLower(str[0]).ToString() : char.ToLower(str[0]) + str[1..];
|
||||
|
||||
return str;
|
||||
}
|
||||
}
|
||||
}
|
||||
|
Loading…
Reference in New Issue
Block a user