File tree Expand file tree Collapse file tree 1 file changed +2
-3
lines changed
app/code/Magento/Payment/Gateway/Helper Expand file tree Collapse file tree 1 file changed +2
-3
lines changed Original file line number Diff line number Diff line change @@ -34,8 +34,7 @@ public static function readPayment(array $subject)
34
34
*/
35
35
public static function readAmount (array $ subject )
36
36
{
37
- if (!isset ($ subject ['amount ' ])
38
- || $ subject ['amount ' ] && !is_numeric ($ subject ['amount ' ])) {
37
+ if (!isset ($ subject ['amount ' ]) || !is_numeric ($ subject ['amount ' ])) {
39
38
throw new \InvalidArgumentException ('Amount should be provided ' );
40
39
}
41
40
@@ -50,7 +49,7 @@ public static function readAmount(array $subject)
50
49
*/
51
50
public static function readField (array $ subject )
52
51
{
53
- if (!isset ($ subject ['field ' ]) && !is_string ($ subject ['field ' ])) {
52
+ if (!isset ($ subject ['field ' ]) || !is_string ($ subject ['field ' ])) {
54
53
throw new \InvalidArgumentException ();
55
54
}
56
55
You can’t perform that action at this time.
0 commit comments