mirror of
https://github.com/jesseduffield/lazygit.git
synced 2025-08-24 19:39:16 +02:00
Cleanup: remove dead code
Cancelling searching (as opposed to filtering) is handled by gocui.
This commit is contained in:
@@ -58,17 +58,12 @@ func (self *QuitActions) Escape() error {
|
||||
}
|
||||
}
|
||||
|
||||
switch ctx := currentContext.(type) {
|
||||
case types.IFilterableContext:
|
||||
// Cancelling searching (as opposed to filtering) is handled by gocui
|
||||
if ctx, ok := currentContext.(types.IFilterableContext); ok {
|
||||
if ctx.IsFiltering() {
|
||||
self.c.Helpers().Search.Cancel()
|
||||
return nil
|
||||
}
|
||||
case types.ISearchableContext:
|
||||
if ctx.IsSearching() {
|
||||
self.c.Helpers().Search.Cancel()
|
||||
return nil
|
||||
}
|
||||
}
|
||||
|
||||
parentContext := currentContext.GetParentContext()
|
||||
|
Reference in New Issue
Block a user