mirror of
https://github.com/OpenTTD/OpenTTD
synced 2026-01-16 08:52:40 +01:00
Codechange: Prefer string equality instead of comparison. (#14727)
This commit is contained in:
@@ -1547,7 +1547,7 @@ StringList GetGRFPresetList()
|
||||
|
||||
ConfigIniFile ini(_config_file);
|
||||
for (const IniGroup &group : ini.groups) {
|
||||
if (group.name.compare(0, 7, "preset-") == 0) {
|
||||
if (group.name.starts_with("preset-")) {
|
||||
list.push_back(group.name.substr(7));
|
||||
}
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user