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

Ensure ruby versions older than 2.3 function correctly #30

Merged
merged 2 commits into from
Feb 13, 2020

Conversation

binford2k
Copy link
Contributor

@binford2k binford2k commented Feb 12, 2020

Fixes #28

@binford2k binford2k requested a review from a team as a code owner February 12, 2020 21:18
Co-Authored-By: Michael T Lombardi (He/Him) <[email protected]>
@michaeltlombardi michaeltlombardi added the bug Something isn't working label Feb 13, 2020
@michaeltlombardi michaeltlombardi changed the title Fix support for older ruby Ensure ruby versions older than 2.3 function correctly Feb 13, 2020
@michaeltlombardi michaeltlombardi merged commit a1b1e59 into puppetlabs:master Feb 13, 2020
@michaeltlombardi michaeltlombardi added bugfix and removed bug Something isn't working labels Feb 13, 2020
@@ -54,7 +54,7 @@ def self.instance(cmd, args, options = {})
if manager.nil? || !manager.alive?
# ignore any errors trying to tear down this unusable instance
begin
manager&.exit
manager.exit if defined?(manager)
Copy link
Contributor

@glennsarti glennsarti Feb 13, 2020

Choose a reason for hiding this comment

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

This should really be manager.exit unless manager.nil?

defined?(manager) will still be true it manager == nil

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Broken for Puppet <6 due to use of Ruby 2.0+ features
3 participants