Fix error with missing usage info (#195)

This commit is contained in:
Joona Hoikkala 2020-03-21 14:52:12 +02:00 committed by GitHub
parent ef1aac3a1e
commit 404c048835
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23

View File

@ -54,7 +54,7 @@ func Usage() {
Description: "Options controlling the HTTP request and its parts.", Description: "Options controlling the HTTP request and its parts.",
Flags: make([]UsageFlag, 0), Flags: make([]UsageFlag, 0),
Hidden: false, Hidden: false,
ExpectedFlags: []string{"H", "X", "b", "d", "r", "u", "recursion", "recursion-depth", "replay-proxy", "timeout", "x"}, ExpectedFlags: []string{"H", "X", "b", "d", "r", "u", "recursion", "recursion-depth", "replay-proxy", "timeout", "ignore-body", "x"},
} }
u_general := UsageSection{ u_general := UsageSection{
Name: "GENERAL OPTIONS", Name: "GENERAL OPTIONS",
@ -115,7 +115,7 @@ func Usage() {
} }
} }
if !found { if !found {
fmt.Printf("DEBUG: Flag %s was found but not defined in usage.go.\n", f.Name) fmt.Printf("DEBUG: Flag %s was found but not defined in help.go.\n", f.Name)
os.Exit(1) os.Exit(1)
} }
if len(f.Name) > max_length { if len(f.Name) > max_length {