Skip to content

Commit e16430e

Browse files
github-actions[bot]GitHub CopilotCopilot
authored
[code-simplifier] refactor: fix orphaned comments in schema_validation.go (#19100)
* refactor: fix orphaned comments in schema_validation.go Remove stale comments referencing old function names (ValidateMainWorkflowFrontmatterWithSchema and ValidateIncludedFileFrontmatterWithSchema) that were disconnected from their renamed counterparts. Merge the detailed description block into the proper doc comment for ValidateMainWorkflowFrontmatterWithSchemaAndLocation. Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com> * ci: trigger CI checks --------- Co-authored-by: GitHub Copilot <copilot@github.com> Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com> Co-authored-by: github-actions[bot] <github-actions[bot]@users.noreply.github.com>
1 parent 67e762b commit e16430e

1 file changed

Lines changed: 1 addition & 5 deletions

File tree

pkg/parser/schema_validation.go

Lines changed: 1 addition & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -44,7 +44,7 @@ func validateSharedWorkflowFields(frontmatter map[string]any) error {
4444
return nil
4545
}
4646

47-
// ValidateMainWorkflowFrontmatterWithSchema validates main workflow frontmatter using JSON schema
47+
// ValidateMainWorkflowFrontmatterWithSchemaAndLocation validates main workflow frontmatter with file location info.
4848
//
4949
// This function validates all frontmatter fields including pass-through fields that are
5050
// extracted and passed directly to GitHub Actions (concurrency, container, environment, env,
@@ -54,8 +54,6 @@ func validateSharedWorkflowFields(frontmatter map[string]any) error {
5454
// - Invalid additional properties (e.g., unknown fields)
5555
//
5656
// See pkg/parser/schema_passthrough_validation_test.go for comprehensive test coverage.
57-
58-
// ValidateMainWorkflowFrontmatterWithSchemaAndLocation validates main workflow frontmatter with file location info
5957
func ValidateMainWorkflowFrontmatterWithSchemaAndLocation(frontmatter map[string]any, filePath string) error {
6058
schemaValidationLog.Printf("Validating main workflow frontmatter: file=%s, fields=%d", filePath, len(frontmatter))
6159
// Filter out ignored fields before validation
@@ -75,8 +73,6 @@ func ValidateMainWorkflowFrontmatterWithSchemaAndLocation(frontmatter map[string
7573
return validateEngineSpecificRules(filtered)
7674
}
7775

78-
// ValidateIncludedFileFrontmatterWithSchema validates included file frontmatter using JSON schema
79-
8076
// ValidateIncludedFileFrontmatterWithSchemaAndLocation validates included file frontmatter with file location info
8177
func ValidateIncludedFileFrontmatterWithSchemaAndLocation(frontmatter map[string]any, filePath string) error {
8278
schemaValidationLog.Printf("Validating included file frontmatter: file=%s, fields=%d", filePath, len(frontmatter))

0 commit comments

Comments
 (0)