virtual_merchant 0.0.7 → 0.0.8
Sign up to get free protection for your applications and to get access to all the features.
- data/lib/virtual_merchant/response.rb +3 -1
- metadata +1 -1
@@ -1,13 +1,15 @@
|
|
1
1
|
class VMResponse
|
2
2
|
attr_accessor :result_message, :result, :blurred_card_number, :exp_date, :approval_code,
|
3
|
-
:cvv2_response, :transaction_id, :transaction_time, :error
|
3
|
+
:cvv2_response, :transaction_id, :transaction_time, :error, :approved
|
4
4
|
|
5
5
|
def initialize(info)
|
6
6
|
@result_message = info[:result_message]
|
7
7
|
if info[:error]
|
8
8
|
@result_type = "error"
|
9
9
|
@error = info[:error]
|
10
|
+
@approved = false
|
10
11
|
else
|
12
|
+
@approved = true
|
11
13
|
@result_type = "approval"
|
12
14
|
@result = info[:result]
|
13
15
|
@blurred_card_number = info[:blurred_card_number]
|