diff options
Diffstat (limited to 'lib/puppet/network/client/proxy.rb')
-rw-r--r-- | lib/puppet/network/client/proxy.rb | 38 |
1 files changed, 19 insertions, 19 deletions
diff --git a/lib/puppet/network/client/proxy.rb b/lib/puppet/network/client/proxy.rb index d3fc9d142..1d565a83a 100644 --- a/lib/puppet/network/client/proxy.rb +++ b/lib/puppet/network/client/proxy.rb @@ -2,26 +2,26 @@ # is basically just a proxy class -- it calls its methods on the driver # and that's about it class Puppet::Network::Client::ProxyClient < Puppet::Network::Client - def self.mkmethods - interface = self.handler.interface - namespace = interface.prefix + def self.mkmethods + interface = self.handler.interface + namespace = interface.prefix - interface.methods.each { |ary| - method = ary[0] - Puppet.debug "#{self}: defining #{namespace}.#{method}" - define_method(method) { |*args| - begin - @driver.send(method, *args) - rescue XMLRPC::FaultException => detail - #Puppet.err "Could not call %s.%s: %s" % - # [namespace, method, detail.faultString] - #raise NetworkClientError, - # "XMLRPC Error: #{detail.faultString}" - raise NetworkClientError, detail.faultString - end - } - } - end + interface.methods.each { |ary| + method = ary[0] + Puppet.debug "#{self}: defining #{namespace}.#{method}" + define_method(method) { |*args| + begin + @driver.send(method, *args) + rescue XMLRPC::FaultException => detail + #Puppet.err "Could not call %s.%s: %s" % + # [namespace, method, detail.faultString] + #raise NetworkClientError, + # "XMLRPC Error: #{detail.faultString}" + raise NetworkClientError, detail.faultString + end + } + } + end end |