This repository was archived by the owner on Dec 5, 2022. It is now read-only.
Do not modify Vagrant core object - #135
Merged
Merged
Conversation
Using [Array#keep_if](http://www.ruby-doc.org/core-1.9.3/Array.html#method-i-keep_if) on a Vagrant core object can lead to unpredictable behaviour down the line as it modifies the object instead of creating a new one. An example of such interference is described on c10l/vagrant-butcher#57. The problem with `keep_if` was identified by @sethvargo on this issue: hashicorp/vagrant#5060 (comment)
|
👍 |
Owner
|
This LGTM but I'll hold back on merging since I'm on vacations away from a computer and wont be able to cut a release. I think there are other contributors around with permission to merge this PR and push a new release to rubygems. If not I'll take care of that when I'm back. Thanks a lot for the patch and sorry for the upcoming silence 😁 |
Owner
|
Thanks and sorry it took so long! The 1.2.0 version of the plugin will come out with this in a few ;-) |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to subscribe to this conversation on GitHub.
Already have an account?
Sign in.
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Using Array#keep_if on a Vagrant core object can lead to unpredictable behaviour down the line as it modifies the object instead of creating a new one.
An example of such interference is described on c10l/vagrant-butcher#57. The problem with
keep_ifwas identified by @sethvargo on this issue: hashicorp/vagrant#5060 (comment)