Skip to content

Commit b7e5394

Browse files
authored
fix: segmentation violation during serve (#1215)
Signed-off-by: Kay Yan <[email protected]>
1 parent ad117a5 commit b7e5394

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

cmd/serve/serve.go

+1-1
Original file line numberDiff line numberDiff line change
@@ -149,7 +149,7 @@ var ServeCmd = &cobra.Command{
149149
}
150150
}
151151

152-
if aiProvider.Name == "" {
152+
if aiProvider == nil || aiProvider.Name == "" {
153153
color.Red("Error: AI provider %s not specified in configuration. Please run k8sgpt auth", backend)
154154
os.Exit(1)
155155
}

0 commit comments

Comments
 (0)