Showing 94 of 94 total issues
Payment
has 43 functions (exceeds 20 allowed). Consider refactoring. Open
Open
class Payment implements PaymentFacade
{
/**
* Available drivers
*
Method getPaymentLink
has 10 arguments (exceeds 4 allowed). Consider refactoring. Open
Open
public function getPaymentLink($orderId,
$paymentId,
float $amount,
string $currency = self::CURRENCY_RUR,
string $paymentType = self::PAYMENT_TYPE_CARD,
Method getPaymentLink
has 10 arguments (exceeds 4 allowed). Consider refactoring. Open
Open
public function getPaymentLink($orderId,
$paymentId,
float $amount,
string $currency = self::CURRENCY_RUR,
string $paymentType = self::PAYMENT_TYPE_CARD,
Method getPaymentForm
has 10 arguments (exceeds 4 allowed). Consider refactoring. Open
Open
public function getPaymentForm($orderId,
$paymentId,
float $amount,
string $currency = self::CURRENCY_RUR,
string $paymentType = self::PAYMENT_TYPE_CARD,
Method getPaymentForm
has 10 arguments (exceeds 4 allowed). Consider refactoring. Open
Open
public function getPaymentForm($orderId,
$paymentId,
float $amount,
string $currency = self::CURRENCY_RUR,
string $paymentType = self::PAYMENT_TYPE_CARD,
Method initPayment
has 7 arguments (exceeds 4 allowed). Consider refactoring. Open
Open
public function initPayment(string $token, string $orderId, string $paymentId, float $amount, string $description, string $currency = PayService::CURRENCY_RUR_ISO, array $extraParams = []): bool;
Avoid variables with short names like $id. Configured minimum length is 3. Open
Open
public function getSchedule(string $id): RecurringSchedule;
- Read upRead up
- Exclude checks
ShortVariable
Since: 0.2
Detects when a field, local, or parameter has a very short name.
Example
class Something {
private $q = 15; // VIOLATION - Field
public static function main( array $as ) { // VIOLATION - Formal
$r = 20 + $this->q; // VIOLATION - Local
for (int $i = 0; $i < 10; $i++) { // Not a Violation (inside FOR)
$r += $this->q;
}
}
}
Source https://phpmd.org/rules/naming.html#shortvariable
Avoid variables with short names like $id. Configured minimum length is 3. Open
Open
public function getTransactionStatus($id): string;
- Read upRead up
- Exclude checks
ShortVariable
Since: 0.2
Detects when a field, local, or parameter has a very short name.
Example
class Something {
private $q = 15; // VIOLATION - Field
public static function main( array $as ) { // VIOLATION - Formal
$r = 20 + $this->q; // VIOLATION - Local
for (int $i = 0; $i < 10; $i++) { // Not a Violation (inside FOR)
$r += $this->q;
}
}
}
Source https://phpmd.org/rules/naming.html#shortvariable
Avoid variables with short names like $id. Configured minimum length is 3. Open
Open
public function setAccountId(string $id): self;
- Read upRead up
- Exclude checks
ShortVariable
Since: 0.2
Detects when a field, local, or parameter has a very short name.
Example
class Something {
private $q = 15; // VIOLATION - Field
public static function main( array $as ) { // VIOLATION - Formal
$r = 20 + $this->q; // VIOLATION - Local
for (int $i = 0; $i < 10; $i++) { // Not a Violation (inside FOR)
$r += $this->q;
}
}
}
Source https://phpmd.org/rules/naming.html#shortvariable
Avoid variables with short names like $id. Configured minimum length is 3. Open
Open
public function setUserId(string $id): self;
- Read upRead up
- Exclude checks
ShortVariable
Since: 0.2
Detects when a field, local, or parameter has a very short name.
Example
class Something {
private $q = 15; // VIOLATION - Field
public static function main( array $as ) { // VIOLATION - Formal
$r = 20 + $this->q; // VIOLATION - Local
for (int $i = 0; $i < 10; $i++) { // Not a Violation (inside FOR)
$r += $this->q;
}
}
}
Source https://phpmd.org/rules/naming.html#shortvariable
Avoid variables with short names like $id. Configured minimum length is 3. Open
Open
public function approveTransaction($id): bool;
- Read upRead up
- Exclude checks
ShortVariable
Since: 0.2
Detects when a field, local, or parameter has a very short name.
Example
class Something {
private $q = 15; // VIOLATION - Field
public static function main( array $as ) { // VIOLATION - Formal
$r = 20 + $this->q; // VIOLATION - Local
for (int $i = 0; $i < 10; $i++) { // Not a Violation (inside FOR)
$r += $this->q;
}
}
}
Source https://phpmd.org/rules/naming.html#shortvariable
Method __construct
has 5 arguments (exceeds 4 allowed). Consider refactoring. Open
Open
public function __construct(string $name = null, int $qty = null, float $price = null, int $tax = null, string $currency = 'RUR')
The closing parenthesis of a multi-line function declaration must be on a new line Open
Open
Receipt $receipt = null): Form;
- Exclude checks
Multi-line function declaration not indented correctly; expected 8 spaces but found 35 Open
Open
string $paymentType = self::PAYMENT_TYPE_CARD,
- Exclude checks
Multi-line function declaration not indented correctly; expected 8 spaces but found 35 Open
Open
string $successReturnUrl = '',
- Exclude checks
Multi-line function declaration not indented correctly; expected 8 spaces but found 35 Open
Open
Receipt $receipt = null): string
- Exclude checks
Multi-line function declaration not indented correctly; expected 8 spaces but found 35 Open
Open
array $extraParams = [],
- Exclude checks
Multi-line function declaration not indented correctly; expected 8 spaces but found 35 Open
Open
$paymentId,
- Exclude checks
The first parameter of a multi-line function declaration must be on the line after the opening bracket Open
Open
public function getPaymentForm($orderId,
- Exclude checks
Multi-line function declaration not indented correctly; expected 8 spaces but found 35 Open
Open
$paymentId,
- Exclude checks