mirror of
https://github.com/vcmi/vcmi.git
synced 2025-08-08 22:26:51 +02:00
Fix crash on attempting to rename preset to the same name
This commit is contained in:
@@ -468,7 +468,7 @@ void StartGameTab::on_buttonPresetRename_clicked()
|
||||
currentName,
|
||||
&ok);
|
||||
|
||||
if (ok && !newName.isEmpty())
|
||||
if (ok && !newName.isEmpty() && newName != currentName)
|
||||
{
|
||||
getMainWindow()->getModView()->renamePreset(currentName, newName);
|
||||
refreshPresets();
|
||||
|
Reference in New Issue
Block a user