Skip to content

Commit 73dfe05

Browse files
authored
[WIP] Fix lint Go issues (#8705)
1 parent e69a5b5 commit 73dfe05

File tree

3 files changed

+2
-10
lines changed

3 files changed

+2
-10
lines changed

pkg/workflow/compiler_safe_outputs_core.go

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -959,7 +959,7 @@ func (c *Compiler) addHandlerManagerConfigEnvVar(steps *[]string, data *Workflow
959959
if cfg.Target != "" {
960960
handlerConfig["target"] = cfg.Target
961961
}
962-
if cfg.RequiredLabels != nil && len(cfg.RequiredLabels) > 0 {
962+
if len(cfg.RequiredLabels) > 0 {
963963
handlerConfig["required_labels"] = cfg.RequiredLabels
964964
}
965965
if cfg.RequiredTitlePrefix != "" {
@@ -974,7 +974,7 @@ func (c *Compiler) addHandlerManagerConfigEnvVar(steps *[]string, data *Workflow
974974
if cfg.Max > 0 {
975975
handlerConfig["max"] = cfg.Max
976976
}
977-
if cfg.AllowedReasons != nil && len(cfg.AllowedReasons) > 0 {
977+
if len(cfg.AllowedReasons) > 0 {
978978
handlerConfig["allowed_reasons"] = cfg.AllowedReasons
979979
}
980980
config["hide_comment"] = handlerConfig

pkg/workflow/compiler_safe_outputs_prs.go

Lines changed: 0 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -1,11 +1,5 @@
11
package workflow
22

3-
import (
4-
"github.com/githubnext/gh-aw/pkg/logger"
5-
)
6-
7-
var prSafeOutputsLog = logger.New("workflow:compiler_safe_outputs_prs")
8-
93
// buildMarkPullRequestAsReadyForReviewStepConfig builds the configuration for marking a PR as ready for review
104
func (c *Compiler) buildMarkPullRequestAsReadyForReviewStepConfig(data *WorkflowData, mainJobName string, threatDetectionEnabled bool) SafeOutputStepConfig {
115
cfg := data.SafeOutputs.MarkPullRequestAsReadyForReview

pkg/workflow/js.go

Lines changed: 0 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -27,8 +27,6 @@ func getAddReviewerScript() string { return "" }
2727
func getAssignMilestoneScript() string { return "" }
2828
func getAssignToAgentScript() string { return "" }
2929
func getAssignToUserScript() string { return "" }
30-
func getCloseDiscussionScript() string { return "" }
31-
func getCloseIssueScript() string { return "" }
3230
func getMarkPullRequestAsReadyForReviewScript() string { return "" }
3331
func getCreateCodeScanningAlertScript() string { return "" }
3432
func getCreateDiscussionScript() string { return "" }

0 commit comments

Comments
 (0)