mirror of
https://github.com/jesseduffield/lazygit.git
synced 2025-04-15 11:56:37 +02:00
Compare contexts with keys
We don't want to compare contexts directly given they are interfaces and not pointers to structs
This commit is contained in:
parent
114ad52ff6
commit
9592686629
@ -95,7 +95,7 @@ func (self *ContextMgr) pushToContextStack(c types.Context) ([]types.Context, ty
|
|||||||
defer self.Unlock()
|
defer self.Unlock()
|
||||||
|
|
||||||
if len(self.ContextStack) > 0 &&
|
if len(self.ContextStack) > 0 &&
|
||||||
c == self.ContextStack[len(self.ContextStack)-1] {
|
c.GetKey() == self.ContextStack[len(self.ContextStack)-1].GetKey() {
|
||||||
// Context being pushed is already on top of the stack: nothing to
|
// Context being pushed is already on top of the stack: nothing to
|
||||||
// deactivate or activate
|
// deactivate or activate
|
||||||
return contextsToDeactivate, nil
|
return contextsToDeactivate, nil
|
||||||
|
Loading…
x
Reference in New Issue
Block a user