Fix a crash that can occur when using Back to Turn.

This commit is contained in:
Celtic Minstrel 2024-02-15 23:15:18 -05:00
parent 17ea7cd2c2
commit fb8dd0f27b

View file

@ -405,7 +405,7 @@ wml_hotkey_record::wml_hotkey_record(const std::string& id, const t_string& desc
}
// Record the cleanup handler
cleanup_ = [i = iter] { registered_hotkeys.erase(i); };
cleanup_ = [id] { registered_hotkeys.erase(id); };
}
wml_hotkey_record::~wml_hotkey_record()