Skip to content
This repository has been archived by the owner on Jun 4, 2021. It is now read-only.

Commit

Permalink
Fix call to super when raising DebugKitBadVersion
Browse files Browse the repository at this point in the history
In Ruby, `super` implicitly passes a copy of the arguments a method received.
When raising a `DebugKitBadVersion` error, the `initialize` method has a
different signature than `super`, so we must explicitly pass the right
arguments.

Fixes GH-1.
  • Loading branch information
Sharpie committed Jun 19, 2014
1 parent 87848c3 commit f7fd039
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion lib/puppet_debugging_kit/plugin_checks.rb
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,7 @@ class DebugKitBadVersion < Vagrant::Errors::VagrantError
def initialize(plugin, required, actual)
@error_message = "Outdated debugging kit dependency: #{plugin}\nMinimum required version is: #{required}\nInstalled version is: #{actual}\nTry: vagrant plugin update #{plugin}"

super
super @error_message
end

def error_message; @error_message; end
Expand Down

0 comments on commit f7fd039

Please sign in to comment.