rack-payment 0.1.2 → 0.1.3

Sign up to get free protection for your applications and to get access to all the features.
@@ -6,12 +6,17 @@ module Rack #:nodoc:
6
6
  #
7
7
  # {Rack::Payment::Helper} is the main API for working with {Rack::Payment}. You use it to:
8
8
  #
9
- # * Set the {#amount} you want to charge someone
10
- # * Spit out the HTML for a credit card / billing information {#form} into your own application
11
- # * Set the {#credit_card} and {#billing_address} to be used when processing the payment
12
- # * Get {#errors} if something didn't work
13
- # * Get the {#response} from your billing gateway after charging (or attempting to charge) someone
14
- # * Get the URL to the image for a {#paypal_express_button}
9
+ # Set the {#amount} you want to charge someone
10
+ #
11
+ # Spit out the HTML for a credit card / billing information {#form} into your own application
12
+ #
13
+ # Set the {#credit_card} and {#billing_address} to be used when processing the payment
14
+ #
15
+ # Get {#errors} if something didn't work
16
+ #
17
+ # Get the {#response} from your billing gateway after charging (or attempting to charge) someon
18
+ #
19
+ # Get the URL to the image for a {#paypal_express_button}
15
20
  #
16
21
  class Helper
17
22
  extend Forwardable
@@ -205,6 +205,12 @@ module Rack #:nodoc:
205
205
  new_env = env.clone
206
206
  new_env['PATH_INFO'] = on_success
207
207
  new_env['REQUEST_METHOD'] = 'GET'
208
+
209
+ # For Rails
210
+ new_env.delete 'action_controller.rescue.request'
211
+ new_env.delete 'action_controller.rescue.response'
212
+ new_env.delete 'REQUEST_URI'
213
+
208
214
  app.call new_env
209
215
  else
210
216
  # on_success has not been overriden ... let's just display out own info
metadata CHANGED
@@ -1,7 +1,7 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: rack-payment
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.1.2
4
+ version: 0.1.3
5
5
  platform: ruby
6
6
  authors:
7
7
  - remi
@@ -9,7 +9,7 @@ autorequire:
9
9
  bindir: bin
10
10
  cert_chain: []
11
11
 
12
- date: 2010-01-29 00:00:00 -07:00
12
+ date: 2010-01-30 00:00:00 -07:00
13
13
  default_executable:
14
14
  dependencies:
15
15
  - !ruby/object:Gem::Dependency