Skip to content

Commit

Permalink
Fix context list nil pointer when no active context was given. (#252)
Browse files Browse the repository at this point in the history
  • Loading branch information
LKaemmerling committed Jul 17, 2020
1 parent 8245b2f commit 5fc1464
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion cli/context_list.go
Original file line number Diff line number Diff line change
Expand Up @@ -57,7 +57,7 @@ func runContextList(cli *CLI, cmd *cobra.Command, args []string) error {
Token: context.Token,
Active: " ",
}
if cli.Config.ActiveContext.Name == context.Name {
if cli.Config.ActiveContext != nil && cli.Config.ActiveContext.Name == context.Name {
presentation.Active = "*"
}

Expand Down

0 comments on commit 5fc1464

Please sign in to comment.