aboutsummaryrefslogtreecommitdiffstats
path: root/commands
diff options
context:
space:
mode:
Diffstat (limited to 'commands')
-rw-r--r--commands/commands.go3
1 files changed, 3 insertions, 0 deletions
diff --git a/commands/commands.go b/commands/commands.go
index 59f87321..9366be9c 100644
--- a/commands/commands.go
+++ b/commands/commands.go
@@ -125,6 +125,9 @@ func (cmds *Commands) ExecuteCommand(
if err != nil {
return err
}
+ if len(args) == 0 {
+ return errors.New("Expected a command after template evaluation.")
+ }
if cmd, ok := cmds.dict()[args[0]]; ok {
log.Tracef("executing command %v", args)
return cmd.Execute(aerc, args)