mirror of
https://github.com/jesseduffield/lazygit.git
synced 2025-05-11 12:25:47 +02:00
Remove ErrorMsg
There is no reason any more for application code to show error messages in a panel. Just return an error instead.
This commit is contained in:
parent
723b92916d
commit
caad553502
27 changed files with 98 additions and 73 deletions
|
@ -1,6 +1,7 @@
|
|||
package custom_commands
|
||||
|
||||
import (
|
||||
"errors"
|
||||
"fmt"
|
||||
"strings"
|
||||
"text/template"
|
||||
|
@ -103,7 +104,7 @@ func (self *HandlerCreator) call(customCommand config.CustomCommand) func() erro
|
|||
return self.confirmPrompt(resolvedPrompt, g)
|
||||
}
|
||||
default:
|
||||
return self.c.ErrorMsg("custom command prompt must have a type of 'input', 'menu', 'menuFromCommand', or 'confirm'")
|
||||
return errors.New("custom command prompt must have a type of 'input', 'menu', 'menuFromCommand', or 'confirm'")
|
||||
}
|
||||
}
|
||||
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue