mirror of
https://github.com/vcmi/vcmi.git
synced 2025-06-15 00:05:02 +02:00
Prevent shadowing of function arguments by local vars
This commit is contained in:
@ -277,9 +277,9 @@ void CHeroList::update(const CGHeroInstance * hero)
|
||||
listBox->resize(LOCPLINT->wanderingHeroes.size());
|
||||
if (adventureInt->selection)
|
||||
{
|
||||
auto hero = dynamic_cast<const CGHeroInstance *>(adventureInt->selection);
|
||||
if (hero)
|
||||
select(hero);
|
||||
auto selectedHero = dynamic_cast<const CGHeroInstance *>(adventureInt->selection);
|
||||
if (selectedHero)
|
||||
select(selectedHero);
|
||||
}
|
||||
CList::update();
|
||||
}
|
||||
|
Reference in New Issue
Block a user