MCPcopy Create free account
hub / github.com/compozy/agh / parseOptionalReviewStatus

Function parseOptionalReviewStatus

internal/cli/task.go:2742–2752  ·  view source on GitHub ↗
(raw string)

Source from the content-addressed store, hash-verified

2740}
2741
2742func parseOptionalReviewStatus(raw string) (taskpkg.RunReviewStatus, error) {
2743 trimmed := strings.TrimSpace(raw)
2744 if trimmed == "" {
2745 return "", nil
2746 }
2747 status := taskpkg.RunReviewStatus(trimmed).Normalize()
2748 if err := status.Validate("review_status"); err != nil {
2749 return "", fmt.Errorf("cli: %w", err)
2750 }
2751 return status, nil
2752}
2753
2754func parseRequiredReviewOutcome(raw string) (taskpkg.RunReviewOutcome, error) {
2755 outcome := taskpkg.RunReviewOutcome(strings.TrimSpace(raw)).Normalize()

Callers 1

Calls 2

ValidateMethod · 0.65
NormalizeMethod · 0.45

Tested by

no test coverage detected