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
1 changed files with 1 additions and 1 deletions
|
@ -129,7 +129,7 @@ func CompletionFromList(aerc *widgets.Aerc, valid []string, args []string) []str
|
||||||
if len(args) == 0 {
|
if len(args) == 0 {
|
||||||
return valid
|
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 {
|
func GetLabels(aerc *widgets.Aerc, args []string) []string {
|
||||||
|
|
Loading…
Reference in a new issue