Make unnecessary hpa public funcs private
Previously `pkg.controller.podautoscaler.UnsafeConvertToVersion` was exported. However, it was never used outside of the `podautoscaler` package. Make it private to prevent confusion. Additionally, move the two private functions in `horizontal.go` to be with the other private functions at the bottom of the file - imho its more readable than having them directly at the top of the file, before the public type and function definitions.
This commit is contained in:
@@ -232,7 +232,7 @@ func (tc *testCase) prepareTestClient(t *testing.T) (*fake.Clientset, *metricsfa
|
||||
}
|
||||
|
||||
// and... convert to autoscaling v1 to return the right type
|
||||
objv1, err := UnsafeConvertToVersionVia(obj, autoscalingv1.SchemeGroupVersion)
|
||||
objv1, err := unsafeConvertToVersionVia(obj, autoscalingv1.SchemeGroupVersion)
|
||||
if err != nil {
|
||||
return true, nil, err
|
||||
}
|
||||
|
Reference in New Issue
Block a user