Browse files

fix for not firing method_missing for capture

  • Loading branch information...
1 parent 2fed02a commit cec659063082e8b771614a72a7b3f85567006669 Neeraj Singh committed Nov 8, 2011
Showing with 6 additions and 1 deletion.
  1. +6 −1 lib/binary_merchant/gateway.rb
View
7 lib/binary_merchant/gateway.rb
@@ -1,5 +1,4 @@
module BinaryMerchant
-
class Gateway
attr_reader :gateway
@@ -13,6 +12,12 @@ def self.logger=(_logger)
gateway.class.logger = @logger if gateway
end
+ # this is needed because ActiveSupport adds a method called
+ # capture becase of which method_missing is not fired
+ def capture(*args, &block)
+ gateway.send(:capture, *args, &block)
+ end
+
def method_missing(method, *args, &block)
gateway.send(method, *args, &block)
end

0 comments on commit cec6590

Please sign in to comment.