Skip to content

Commit f7dcedb

Browse files
committed
fixed linter
1 parent 8ecb727 commit f7dcedb

File tree

1 file changed

+3
-2
lines changed

1 file changed

+3
-2
lines changed

apix/v1alpha2/inferencepool_conversion.go

Lines changed: 3 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -17,6 +17,7 @@ limitations under the License.
1717
package v1alpha2
1818

1919
import (
20+
"errors"
2021
"fmt"
2122

2223
"k8s.io/apimachinery/pkg/apis/meta/v1/unstructured"
@@ -28,7 +29,7 @@ import (
2829
// ConvertTo converts this InferencePool (v1alpha2) to the v1 version.
2930
func (src *InferencePool) ConvertTo(dst *v1.InferencePool) error {
3031
if dst == nil {
31-
return fmt.Errorf("dst cannot be nil")
32+
return errors.New("dst cannot be nil")
3233
}
3334
v1Extension, err := convertExtensionRefToV1(src.Spec.ExtensionRef)
3435
if err != nil {
@@ -55,7 +56,7 @@ func (src *InferencePool) ConvertTo(dst *v1.InferencePool) error {
5556
// ConvertFrom converts from the v1 version to this version (v1alpha2).
5657
func (dst *InferencePool) ConvertFrom(src *v1.InferencePool) error {
5758
if src == nil {
58-
return fmt.Errorf("src cannot be nil")
59+
return errors.New("src cannot be nil")
5960
}
6061
extensionRef, err := convertExtensionRefFromV1(src.Spec.ExtensionRef)
6162
if err != nil {

0 commit comments

Comments
 (0)