From 74901ae150f509d85fcdaa6939aada2cbb27502f Mon Sep 17 00:00:00 2001 From: root Date: Tue, 17 May 2016 10:01:37 -0400 Subject: [PATCH] No need to log empty string --- plugin/pkg/scheduler/algorithm/predicates/predicates.go | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/plugin/pkg/scheduler/algorithm/predicates/predicates.go b/plugin/pkg/scheduler/algorithm/predicates/predicates.go index 4b1c8c9b5d9..612125032ab 100644 --- a/plugin/pkg/scheduler/algorithm/predicates/predicates.go +++ b/plugin/pkg/scheduler/algorithm/predicates/predicates.go @@ -151,7 +151,7 @@ func (c *MaxPDVolumeCountChecker) filterVolumes(volumes []api.Volume, namespace } else if vol.PersistentVolumeClaim != nil { pvcName := vol.PersistentVolumeClaim.ClaimName if pvcName == "" { - return fmt.Errorf("PersistentVolumeClaim had no name: %q", pvcName) + return fmt.Errorf("PersistentVolumeClaim had no name") } pvc, err := c.pvcInfo.GetPersistentVolumeClaimInfo(namespace, pvcName) if err != nil { @@ -304,7 +304,7 @@ func (c *VolumeZoneChecker) predicate(pod *api.Pod, nodeInfo *schedulercache.Nod if volume.PersistentVolumeClaim != nil { pvcName := volume.PersistentVolumeClaim.ClaimName if pvcName == "" { - return false, fmt.Errorf("PersistentVolumeClaim had no name: %q", pvcName) + return false, fmt.Errorf("PersistentVolumeClaim had no name") } pvc, err := c.pvcInfo.GetPersistentVolumeClaimInfo(namespace, pvcName) if err != nil {