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

tags: Ensure complete removal of tags is working #196

Merged
merged 1 commit into from
Oct 11, 2017

Conversation

vancluever
Copy link
Contributor

tagsClientIfDefined was checking to see if the tags client was defined
as a condition to loading up the tags client for Create and Update
operations. While this generally worked for adding the tags to new
resources and changing tags when necessary, it was not working for
complete tag removal due to its reliance on GetOk, which fails if a
field is removed from config completely.

This fixes tagsClientIfDefined so that it checks both the old and new
incarnations of the tags argument to make sure that both are empty
before passing on loading the tags client.

tagsClientIfDefined was checking to see if the tags client was defined
as a condition to loading up the tags client for Create and Update
operations. While this generally worked for adding the tags to new
resources and changing tags when necessary, it was not working for
complete tag removal due to its reliance on GetOk, which fails if a
field is removed from config completely.

This fixes tagsClientIfDefined so that it checks both the old and new
incarnations of the tags argument to make sure that both are empty
before passing on loading the tags client.
@vancluever vancluever added the bug Type: Bug label Oct 10, 2017
Copy link
Member

@mbfrahry mbfrahry left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM!

@vancluever vancluever merged commit b98dde2 into master Oct 11, 2017
@vancluever
Copy link
Contributor Author

Thanks @mbfrahry!

vancluever added a commit that referenced this pull request Oct 11, 2017
@vancluever vancluever deleted the b-tag-complete-remove branch October 12, 2017 00:30
@ghost ghost locked and limited conversation to collaborators Apr 19, 2020
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
bug Type: Bug
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants