fix the wrong err print of assumepod

This commit is contained in:
zhangxiaoyu-zidif 2018-01-22 10:50:59 +08:00
parent e35d67e032
commit a478db6ada

View File

@ -131,7 +131,7 @@ func (cache *schedulerCache) AssumePod(pod *v1.Pod) error {
cache.mu.Lock()
defer cache.mu.Unlock()
if _, ok := cache.podStates[key]; ok {
return fmt.Errorf("pod %v is not in the cache, so can't be assumed", key)
return fmt.Errorf("pod %v is in the cache, so can't be assumed", key)
}
cache.addPod(pod)