fix(confirm): esc should not exit with 130

This commit is contained in:
Maas Lalani 2023-01-13 12:08:06 -05:00
parent 08ed3e2519
commit 36ef76185c
No known key found for this signature in database
GPG key ID: 5A6ED5CBF1A0A000

View file

@ -58,9 +58,11 @@ func (m model) Update(msg tea.Msg) (tea.Model, tea.Cmd) {
return m, nil
case tea.KeyMsg:
switch msg.String() {
case "ctrl+c", "esc":
m.confirmation = false
case "ctrl+c":
m.aborted = true
fallthrough
case "esc":
m.confirmation = false
m.quitting = true
return m, tea.Quit
case "q", "n", "N":