issuer_response_codes 0.2.3 → 0.2.4
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +4 -4
- data/Gemfile.lock +1 -1
- data/lib/issuer_response_codes/locale_library.rb +6 -2
- data/lib/issuer_response_codes/version.rb +1 -1
- metadata +1 -1
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA256:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: dac9d604f2e19423d50223600a7919c737ad77eaa6d20a81478f36dadc907cbb
|
4
|
+
data.tar.gz: 92cf2b531073ec57418906a5996b3b6fcdfeb2771c3646e7879178e73f836bcd
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: ac1b7680c8c076ac0f06108cc96e685c058fb506240e189f9ea14f7e4ec132d51fd279571bf39a441709adfad8f8bfcc3f798d397d16b82e5ce10f6c7a113937
|
7
|
+
data.tar.gz: 3c106d735298510ae3a73742b8ff40eb264a5cff307eb7cc6cc71a8031d6b3f21d7fdea9cda437e2e178746a48f7b0e597422d7c2248494d743ff2aa94a82891
|
data/Gemfile.lock
CHANGED
@@ -23,6 +23,7 @@ module IssuerResponseCodes
|
|
23
23
|
end
|
24
24
|
|
25
25
|
def issuer_response_codes(locale: :en)
|
26
|
+
fraudulent_codes = locale_hash.dig(locale, :issuer_response_codes, :fraudulent_codes)
|
26
27
|
behaviours = locale_hash.dig(locale, :issuer_response_codes, :behaviour)
|
27
28
|
cardholder_reasons = locale_hash.dig(locale, :issuer_response_codes, :targeted, :cardholder)
|
28
29
|
merchant_reasons = locale_hash.dig(locale, :issuer_response_codes, :targeted, :merchant)
|
@@ -33,13 +34,15 @@ module IssuerResponseCodes
|
|
33
34
|
{
|
34
35
|
merchant_reason: merchant_reason,
|
35
36
|
cardholder_reason: cardholder_reasons[code],
|
36
|
-
behaviour: behaviours[code]
|
37
|
+
behaviour: behaviours[code],
|
38
|
+
fraudulent: fraudulent_codes[code] == true
|
37
39
|
}
|
38
40
|
]
|
39
41
|
end.to_h
|
40
42
|
end
|
41
43
|
|
42
44
|
def tds_codes(locale: :en)
|
45
|
+
fraudulent_codes = locale_hash.dig(locale, :tds_status_codes, :fraudulent_codes)
|
43
46
|
behaviours = locale_hash.dig(locale, :tds_status_codes, :behaviour)
|
44
47
|
cardholder_reasons = locale_hash.dig(locale, :tds_status_codes, :targeted, :cardholder)
|
45
48
|
merchant_reasons = locale_hash.dig(locale, :tds_status_codes, :targeted, :merchant)
|
@@ -50,7 +53,8 @@ module IssuerResponseCodes
|
|
50
53
|
{
|
51
54
|
merchant_reason: merchant_reason,
|
52
55
|
cardholder_reason: cardholder_reasons[code],
|
53
|
-
behaviour: behaviours[code]
|
56
|
+
behaviour: behaviours[code],
|
57
|
+
fraudulent: fraudulent_codes[code] == true
|
54
58
|
}
|
55
59
|
]
|
56
60
|
end.to_h
|