From 97749a27b948268a921ef3e75d679a0f1f5c26ce Mon Sep 17 00:00:00 2001 From: ChristopherHX Date: Thu, 13 Apr 2023 16:09:29 +0200 Subject: [PATCH] fix: ghc assignment typo (#1729) * fix: ghc assignment typo * fixup server_url --- pkg/model/github_context.go | 2 +- pkg/runner/run_context.go | 4 ++-- 2 files changed, 3 insertions(+), 3 deletions(-) diff --git a/pkg/model/github_context.go b/pkg/model/github_context.go index ceb54cd..5ed3d96 100644 --- a/pkg/model/github_context.go +++ b/pkg/model/github_context.go @@ -36,7 +36,7 @@ type GithubContext struct { RetentionDays string `json:"retention_days"` RunnerPerflog string `json:"runner_perflog"` RunnerTrackingID string `json:"runner_tracking_id"` - ServerURL string `json:"server_url "` + ServerURL string `json:"server_url"` APIURL string `json:"api_url"` GraphQLURL string `json:"graphql_url"` } diff --git a/pkg/runner/run_context.go b/pkg/runner/run_context.go index 7ab8d18..1273811 100644 --- a/pkg/runner/run_context.go +++ b/pkg/runner/run_context.go @@ -646,10 +646,10 @@ func (rc *RunContext) getGithubContext(ctx context.Context) *model.GithubContext ghc.ServerURL = rc.Config.Env["GITHUB_SERVER_URL"] } if rc.Config.Env["GITHUB_API_URL"] != "" { - ghc.ServerURL = rc.Config.Env["GITHUB_API_URL"] + ghc.APIURL = rc.Config.Env["GITHUB_API_URL"] } if rc.Config.Env["GITHUB_GRAPHQL_URL"] != "" { - ghc.ServerURL = rc.Config.Env["GITHUB_GRAPHQL_URL"] + ghc.GraphQLURL = rc.Config.Env["GITHUB_GRAPHQL_URL"] } return ghc