commands: fix possible panic in CompletionFromList
Panic might occur if aerc.SelectedAccount() is nil Signed-off-by: kt programs <ktprograms@gmail.com> Acked-by: Robin Jarry <robin@jarry.cc>
This commit is contained in:
parent
2a19c30879
commit
a16bd05321
|
@ -129,7 +129,7 @@ func CompletionFromList(aerc *widgets.Aerc, valid []string, args []string) []str
|
|||
if len(args) == 0 {
|
||||
return valid
|
||||
}
|
||||
return FilterList(valid, args[0], "", aerc.SelectedAccount().UiConfig().FuzzyComplete)
|
||||
return FilterList(valid, args[0], "", aerc.SelectedAccountUiConfig().FuzzyComplete)
|
||||
}
|
||||
|
||||
func GetLabels(aerc *widgets.Aerc, args []string) []string {
|
||||
|
|
Loading…
Reference in New Issue