@@ -20,18 +20,17 @@ import (
20
20
"fmt"
21
21
22
22
jsonpatch "github.com/evanphx/json-patch"
23
- "k8s.io/apimachinery/pkg/runtime"
24
23
"k8s.io/apimachinery/pkg/types"
25
24
"k8s.io/apimachinery/pkg/util/json"
26
25
)
27
26
28
27
var (
29
28
// Apply uses server-side apply to patch the given object.
30
- Apply = applyPatch {}
29
+ Apply Patch = applyPatch {}
31
30
32
31
// Merge uses the raw object as a merge patch, without modifications.
33
32
// Use MergeFrom if you wish to compute a diff instead.
34
- Merge = mergePatch {}
33
+ Merge Patch = mergePatch {}
35
34
)
36
35
37
36
type patch struct {
@@ -89,7 +88,7 @@ type mergeFromPatch struct {
89
88
opts MergeFromOptions
90
89
}
91
90
92
- // Type implements patch .
91
+ // Type implements Patch .
93
92
func (s * mergeFromPatch ) Type () types.PatchType {
94
93
return types .MergePatchType
95
94
}
@@ -153,7 +152,7 @@ func (p mergePatch) Type() types.PatchType {
153
152
}
154
153
155
154
// Data implements Patch.
156
- func (p mergePatch ) Data (obj runtime. Object ) ([]byte , error ) {
155
+ func (p mergePatch ) Data (obj Object ) ([]byte , error ) {
157
156
// NB(directxman12): we might technically want to be using an actual encoder
158
157
// here (in case some more performant encoder is introduced) but this is
159
158
// correct and sufficient for our uses (it's what the JSON serializer in
@@ -170,7 +169,7 @@ func (p applyPatch) Type() types.PatchType {
170
169
}
171
170
172
171
// Data implements Patch.
173
- func (p applyPatch ) Data (obj runtime. Object ) ([]byte , error ) {
172
+ func (p applyPatch ) Data (obj Object ) ([]byte , error ) {
174
173
// NB(directxman12): we might technically want to be using an actual encoder
175
174
// here (in case some more performant encoder is introduced) but this is
176
175
// correct and sufficient for our uses (it's what the JSON serializer in
0 commit comments