class VagrantPlugins::VSphere::Action::CloseVSphere

Public Class Methods

new(app, _env) click to toggle source
# File lib/vSphere/action/close_vsphere.rb, line 7
def initialize(app, _env)
  @app = app
end

Public Instance Methods

call(env) click to toggle source
# File lib/vSphere/action/close_vsphere.rb, line 11
def call(env)
  env[:vSphere_connection].close
  @app.call env
rescue Errors::VSphereError
  raise
rescue StandardError => e
  raise Errors::VSphereError.new, e.message
end