| Total Complexity | 11 |
| Total Lines | 53 |
| Duplicated Lines | 0 % |
| Coverage | 0% |
| Changes | 1 | ||
| Bugs | 0 | Features | 0 |
| 1 | <?php |
||
| 12 | class CompletePurchaseResponse extends AbstractCompletePurchaseResponse |
||
| 13 | { |
||
| 14 | use CompletePurchaseResponseTrait; |
||
| 15 | |||
| 16 | /** |
||
| 17 | * @inheritDoc |
||
| 18 | */ |
||
| 19 | public function isPending() |
||
| 20 | { |
||
| 21 | $model = $this->getModel(); |
||
| 22 | if ($model) { |
||
| 23 | $status = $model->status; |
||
|
|
|||
| 24 | if (empty($status) or $status == 'pending') { |
||
| 25 | return true; |
||
| 26 | } |
||
| 27 | } |
||
| 28 | return parent::isPending(); |
||
| 29 | } |
||
| 30 | |||
| 31 | /** |
||
| 32 | * @inheritDoc |
||
| 33 | */ |
||
| 34 | public function isCancelled() |
||
| 43 | } |
||
| 44 | |||
| 45 | /** |
||
| 46 | * @inheritDoc |
||
| 47 | */ |
||
| 48 | public function isSuccessful() |
||
| 57 | } |
||
| 58 | |||
| 59 | /** @noinspection PhpMissingParentCallCommonInspection |
||
| 60 | * @return bool |
||
| 61 | */ |
||
| 62 | protected function canProcessModel() |
||
| 65 | } |
||
| 66 | } |
||
| 67 |