Codechange: Remove c_str, if std::string_view is already accepted.

This commit is contained in:
frosch
2025-04-30 12:38:02 +02:00
committed by frosch
parent b564fbb5e6
commit 36ce1f890a
7 changed files with 10 additions and 10 deletions
+2 -2
View File
@@ -1155,7 +1155,7 @@ struct NewGRFWindow : public Window, NewGRFScanCallback {
this->preset = index;
if (index != -1) {
this->actives = LoadGRFPresetFromConfig(this->grf_presets[index].c_str());
this->actives = LoadGRFPresetFromConfig(this->grf_presets[index]);
}
this->avails.ForceRebuild();
@@ -1170,7 +1170,7 @@ struct NewGRFWindow : public Window, NewGRFScanCallback {
{
if (!str.has_value()) return;
SaveGRFPresetToConfig(str->c_str(), this->actives);
SaveGRFPresetToConfig(*str, this->actives);
this->grf_presets = GetGRFPresetList();
/* Switch to this preset */