From a081152dc5602beb1889cb15038c6d750963214b Mon Sep 17 00:00:00 2001 From: Unknown Date: Tue, 19 May 2020 17:07:17 -0300 Subject: [PATCH] Remove condition for passing ctx to child command --- command.go | 4 +--- 1 file changed, 1 insertion(+), 3 deletions(-) diff --git a/command.go b/command.go index 7e55dcfd..484d88fd 100644 --- a/command.go +++ b/command.go @@ -949,9 +949,7 @@ func (c *Command) ExecuteC() (cmd *Command, err error) { // We have to pass global context to children command // if context is present on the parent command. - if cmd.ctx == nil { - cmd.ctx = c.ctx - } + cmd.ctx = c.ctx err = cmd.execute(flags) if err != nil {