mirror of
https://github.com/optim-enterprises-bv/kubernetes.git
synced 2025-11-03 11:48:15 +00:00
Introduce GroupVersioner for capturing desired target version
Convert single GV and lists of GVs into an interface that can handle more complex scenarios (everything internal, nothing supported). Pass the interface down into conversion.
This commit is contained in:
@@ -35,7 +35,7 @@ var _ ObjectConvertor = unsafeObjectConvertor{}
|
||||
|
||||
// ConvertToVersion converts in to the provided outVersion without copying the input first, which
|
||||
// is only safe if the output object is not mutated or reused.
|
||||
func (c unsafeObjectConvertor) ConvertToVersion(in Object, outVersion unversioned.GroupVersion) (Object, error) {
|
||||
func (c unsafeObjectConvertor) ConvertToVersion(in Object, outVersion GroupVersioner) (Object, error) {
|
||||
return c.Scheme.UnsafeConvertToVersion(in, outVersion)
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user