Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

impossible to delete last or all host aliases #240

Open
hrez opened this issue Aug 17, 2024 · 0 comments
Open

impossible to delete last or all host aliases #240

hrez opened this issue Aug 17, 2024 · 0 comments

Comments

@hrez
Copy link

hrez commented Aug 17, 2024

Hi,

While I can add or remove aliases in host record, it's impossible to remove all host record aliases using ObjectManager.UpdateHostRecord() by supplying aliases parameter as nil or []string{}

This is due to omitempty in
Aliases []string json:"aliases,omitempty"
in HostRecord

It's true for both v1 and v2.

To test:

  1. create host record with alias(es)
  2. update host record to remove aliases
  3. do GetHostRecord to observe aliases still present.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant