diff --git a/src/ui/groups_widgets.cc b/src/ui/groups_widgets.cc index b5d55a69..824e9330 100644 --- a/src/ui/groups_widgets.cc +++ b/src/ui/groups_widgets.cc @@ -915,7 +915,7 @@ QString DictGroupsWidget::getCurrentGroupName() const const int current = currentIndex(); if ( current >= 0 ) { - auto w = dynamic_cast< DictGroupWidget & >( *widget( x ) ); + auto w = dynamic_cast< DictGroupWidget & >( *widget( current ) ); return w.name(); } @@ -928,7 +928,7 @@ void DictGroupsWidget::renameCurrentGroup( QString const & name ) const int current = currentIndex(); if ( current >= 0 ) { - auto w = dynamic_cast< DictGroupWidget & >( *widget( x ) ); + auto w = dynamic_cast< DictGroupWidget & >( *widget( current ) ); w->setName( name ); setTabText( current, Utils::escapeAmps( name ) ); }