diff options
Diffstat (limited to 'src/pkg/flag/flag.go')
| -rw-r--r-- | src/pkg/flag/flag.go | 6 |
1 files changed, 1 insertions, 5 deletions
diff --git a/src/pkg/flag/flag.go b/src/pkg/flag/flag.go index 0c2589c9e..a0cb4f5ca 100644 --- a/src/pkg/flag/flag.go +++ b/src/pkg/flag/flag.go @@ -239,11 +239,7 @@ func Visit(fn func(*Flag)) { // Lookup returns the Flag structure of the named flag, returning nil if none exists. func Lookup(name string) *Flag { - f, ok := flags.formal[name] - if !ok { - return nil - } - return f + return flags.formal[name] } // Set sets the value of the named flag. It returns true if the set succeeded; false if |
