From 72ee37f33edf9acbb30f15510eec8958fd84da19 Mon Sep 17 00:00:00 2001 From: Viktor Stanchev Date: Wed, 30 Sep 2015 00:09:17 -0700 Subject: [PATCH] fix bug with PersistentPreRunE --- command.go | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/command.go b/command.go index b67e025..0b85345 100644 --- a/command.go +++ b/command.go @@ -522,7 +522,7 @@ func (c *Command) execute(a []string) (err error) { for p := c; p != nil; p = p.Parent() { if p.PersistentPreRunE != nil { - if err := p.PersistentPostRunE(c, argWoFlags); err != nil { + if err := p.PersistentPreRunE(c, argWoFlags); err != nil { return err } break