Skip to content

Commit 10986a0

Browse files
laxmikantbpandhareadoramshoval
authored andcommitted
updated error message according to new discussion
resolved conflicts
1 parent 86ecaf5 commit 10986a0

File tree

2 files changed

+6
-4
lines changed

2 files changed

+6
-4
lines changed

api/internal/builtins/PatchTransformer.go

Lines changed: 3 additions & 2 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

plugin/builtin/patchtransformer/PatchTransformer.go

Lines changed: 3 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -6,6 +6,7 @@ package main
66

77
import (
88
"fmt"
9+
"log"
910
"strings"
1011

1112
jsonpatch "gopkg.in/evanphx/json-patch.v4"
@@ -134,8 +135,8 @@ func (p *plugin) transformJson6902(m resmap.ResMap) error {
134135
return err
135136
}
136137

137-
if len(resources) == 0 {
138-
return fmt.Errorf("patches target not found for %s", p.Target.ResId)
138+
if p.Options["allowNoTargetMatch"] {
139+
log.Println("Warning: patches target not found for Target")
139140
}
140141

141142
for _, res := range resources {

0 commit comments

Comments
 (0)