diff --git a/netbox/netbox.go b/netbox/netbox.go index 6889eb6..03a4401 100644 --- a/netbox/netbox.go +++ b/netbox/netbox.go @@ -189,7 +189,7 @@ func (a *Allocator) AllocCIDR() (cidr string, err error) { return } defer resp.Body.Close() - if resp.StatusCode == http.StatusNoContent { + if resp.StatusCode == http.StatusConflict { return "", netalloc.ErrPrefixFull } if resp.StatusCode == http.StatusCreated {