mirror of
https://git.lyx.org/repos/lyx.git
synced 2024-11-22 10:00:33 +00:00
Remove useless test
Coverity issue 23300.
This commit is contained in:
parent
28e997781d
commit
d786d98c36
@ -1122,12 +1122,10 @@ void MenuDefinition::expandFormats(MenuItem::Kind const kind, Buffer const * buf
|
||||
label += '|' + shortcut;
|
||||
|
||||
if (view_update) {
|
||||
if (buf)
|
||||
item.submenu().addWithStatusCheck(MenuItem(MenuItem::Command,
|
||||
toqstr(label), FuncRequest(action, (*fit)->name())));
|
||||
else
|
||||
item.submenu().add(MenuItem(MenuItem::Command, toqstr(label),
|
||||
FuncRequest(action, (*fit)->name())));
|
||||
// note that at this point, we know that buf is not null
|
||||
LATTEST(buf);
|
||||
item.submenu().addWithStatusCheck(MenuItem(MenuItem::Command,
|
||||
toqstr(label), FuncRequest(action, (*fit)->name())));
|
||||
} else {
|
||||
if (buf)
|
||||
addWithStatusCheck(MenuItem(MenuItem::Command, toqstr(label),
|
||||
|
Loading…
Reference in New Issue
Block a user