Conditions | 3 |
Paths | 3 |
Total Lines | 19 |
Code Lines | 11 |
Lines | 0 |
Ratio | 0 % |
Changes | 1 | ||
Bugs | 1 | Features | 0 |
1 | <?php |
||
20 | public function createFailedAuthMessage(AmazonpayCallTransfer $amazonpayCallTransfer) |
||
21 | { |
||
22 | if ($amazonpayCallTransfer->getAmazonpayPayment() |
||
23 | ->getAuthorizationDetails() |
||
24 | ->getAuthorizationStatus() |
||
25 | ->getIsSuspended() |
||
26 | ) { |
||
27 | return $this->createOrderAuthFailedSoftDeclineMessage($amazonpayCallTransfer); |
||
28 | } |
||
29 | |||
30 | if ($amazonpayCallTransfer->getAmazonpayPayment() |
||
31 | ->getAuthorizationDetails() |
||
32 | ->getAuthorizationStatus() |
||
33 | ->getIsDeclined() |
||
34 | ) { |
||
35 | return $this->createOrderAuthFailedHardDeclineMessage($amazonpayCallTransfer); |
||
36 | } |
||
37 | |||
38 | return null; |
||
39 | } |
||
62 |
This check compares calls to functions or methods with their respective definitions. If the call has more arguments than are defined, it raises an issue.
If a function is defined several times with a different number of parameters, the check may pick up the wrong definition and report false positives. One codebase where this has been known to happen is Wordpress. Please note the @ignore annotation hint above.