in lib/puppet/provider/package/homebrew.rb [137:149]
def uninstall
begin
Puppet.debug "Uninstalling #{resource_name}"
execute([command(:brew), :uninstall, resource_name], :failonfail => true)
rescue Puppet::ExecutionFailure
begin
execute([command(:brew), :uninstall, '--cask', resource_name], :failonfail => true)
rescue Puppet::ExecutionFailure => detail
raise Puppet::Error, "Could not uninstall package: #{detail}"
end
end
end