From 9310f5b8bed9fdb76a8e253770bd0a8b01923b55 Mon Sep 17 00:00:00 2001 From: Brendan Jackman Date: Sat, 27 Dec 2025 18:37:12 +0100 Subject: [PATCH] fix: Fix nil deref in config set command Currently if the user sets --auth.method without --auth.header, if defaultAuther isn't defined then there is a nil deref. Check for nil directly so we can give a helpeful error message instead. --- cmd/config.go | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/cmd/config.go b/cmd/config.go index 4766c389..985ad1ce 100644 --- a/cmd/config.go +++ b/cmd/config.go @@ -99,7 +99,7 @@ func getProxyAuth(flags *pflag.FlagSet, defaultAuther map[string]interface{}) (a return nil, err } - if header == "" { + if header == "" && defaultAuther != nil{ header = defaultAuther["header"].(string) }