From b4f8d4947ff517ae1498d5787ebb34ca3803ad13 Mon Sep 17 00:00:00 2001 From: Loren Burkholder Date: Mon, 27 Feb 2023 18:12:19 -0500 Subject: Simplify code a bit --- src/timeline/InputBar.cpp | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) (limited to 'src/timeline/InputBar.cpp') diff --git a/src/timeline/InputBar.cpp b/src/timeline/InputBar.cpp index 6c882cd4..2491b5c1 100644 --- a/src/timeline/InputBar.cpp +++ b/src/timeline/InputBar.cpp @@ -390,8 +390,7 @@ InputBar::send() auto wasEdit = !room->edit().isEmpty(); - auto [commandName, args] = getCommandAndArgs(); - if (commandName.isNull()) + if (auto [commandName, args] = getCommandAndArgs(); commandName.isNull()) message(text()); else command(commandName, args); -- cgit 1.5.1