Passed
Push — master ( d44c16...e61ae6 )
by Kelvin
03:00
created

chpter_mobile_payout_destination()   A

Complexity

Conditions 1
Paths 1

Size

Total Lines 3
Code Lines 1

Duplication

Lines 0
Ratio 0 %

Importance

Changes 1
Bugs 0 Features 0
Metric Value
cc 1
eloc 1
nc 1
nop 2
dl 0
loc 3
rs 10
c 1
b 0
f 0
1
<?php
2
function chpter_renew_account_token()
3
{
4
    return Kipling\ChpterPhpSdk\Chpter::accountsTokenRenewal();
0 ignored issues
show
Bug introduced by
The type Kipling\ChpterPhpSdk\Chpter was not found. Maybe you did not declare it correctly or list all dependencies?

The issue could also be caused by a filter entry in the build configuration. If the path has been excluded in your configuration, e.g. excluded_paths: ["lib/*"], you can move it to the dependency path list as follows:

filter:
    dependency_paths: ["lib/*"]

For further information see https://scrutinizer-ci.com/docs/tools/php/php-scrutinizer/#list-dependency-paths

Loading history...
5
}
6
7
function chpter_mpesa_payment($customer, $products, $amount, $callback_details)
8
{
9
    return KiplingKelvin\ChpterLaravelSdk\Chpter::mpesaPayment($customer, $products, $amount, $callback_details);
0 ignored issues
show
Bug Best Practice introduced by
The method KiplingKelvin\ChpterLara...\Chpter::mpesaPayment() is not static, but was called statically. ( Ignorable by Annotation )

If this is a false-positive, you can also ignore this issue in your code via the ignore-call  annotation

9
    return KiplingKelvin\ChpterLaravelSdk\Chpter::/** @scrutinizer ignore-call */ mpesaPayment($customer, $products, $amount, $callback_details);
Loading history...
10
}
11
12
function chpter_card_payment($customer, $products, $amount,$card_details, $callback_details)
13
{
14
    return KiplingKelvin\ChpterLaravelSdk\Chpter::cardPayment($customer, $products, $amount,$card_details, $callback_details);
0 ignored issues
show
Bug introduced by
The method cardPayment() does not exist on KiplingKelvin\ChpterLaravelSdk\Chpter. ( Ignorable by Annotation )

If this is a false-positive, you can also ignore this issue in your code via the ignore-call  annotation

14
    return KiplingKelvin\ChpterLaravelSdk\Chpter::/** @scrutinizer ignore-call */ cardPayment($customer, $products, $amount,$card_details, $callback_details);

This check looks for calls to methods that do not seem to exist on a given type. It looks for the method on the type itself as well as in inherited classes or implemented interfaces.

This is most likely a typographical error or the method has been renamed.

Loading history...
15
}
16
function chpter_hosted_redirect_payment($customer, $amount, $redirect_urls)
17
{
18
    return Kipling\ChpterPhpSdk\Chpter::hostedRedirectPayment($customer, $amount, $redirect_urls);
19
}
20
21
function chpter_express_redirect_payment($transaction_data, $redirect_urls)
22
{
23
    return Kipling\ChpterPhpSdk\Chpter::expressRedirectPayment($transaction_data, $redirect_urls);
24
}
25
function chpter_mobile_payout_destination($type, $phone_number)
26
{
27
    return Kipling\ChpterPhpSdk\Payouts::createMobilePayoutDestination($type, $phone_number);
0 ignored issues
show
Bug introduced by
The type Kipling\ChpterPhpSdk\Payouts was not found. Maybe you did not declare it correctly or list all dependencies?

The issue could also be caused by a filter entry in the build configuration. If the path has been excluded in your configuration, e.g. excluded_paths: ["lib/*"], you can move it to the dependency path list as follows:

filter:
    dependency_paths: ["lib/*"]

For further information see https://scrutinizer-ci.com/docs/tools/php/php-scrutinizer/#list-dependency-paths

Loading history...
28
}
29
30
function chpter_bank_payout_destination($bank_name, $bank_account_name, $bank_account_number)
31
{
32
    return Kipling\ChpterPhpSdk\Payouts::createBankPayoutDestination($bank_name, $bank_account_name, $bank_account_number);
33
}
34