Update calico lib

fix struct definition error in v3

Signed-off-by: Duan Jiong <djduanjiong@gmail.com>
This commit is contained in:
Duan Jiong
2021-02-24 18:06:36 +08:00
parent 78c7b81ce5
commit 2705d25e83
8 changed files with 44 additions and 16 deletions

View File

@@ -120,7 +120,7 @@ func (b *AllocationBlock) IsDeleted() bool {
func (b *AllocationBlock) Host() string {
if b.Affinity != nil && strings.HasPrefix(*b.Affinity, "host:") {
return strings.TrimPrefix(*b.Affinity, "host:")
return strings.TrimLeft(*b.Affinity, "host:")
}
return ""
}