includes/abstracts/abstract.llms.payment.gateway.php
LLMS_Payment_Gateway
has 42 functions (exceeds 20 allowed). Consider refactoring. Open
Open
abstract class LLMS_Payment_Gateway extends LLMS_Abstract_Options_Data {
/**
* Optional gateway description for the admin panel
*
File abstract.llms.payment.gateway.php
has 315 lines of code (exceeds 250 allowed). Consider refactoring. Open
Open
<?php
/**
* LifterLMS Payment Gateways Abstract
*
* @package LifterLMS/Abstracts/Classes
Method get_admin_settings_fields
has 49 lines of code (exceeds 25 allowed). Consider refactoring. Open
Open
public function get_admin_settings_fields() {
$fields = array();
$fields[] = array(
Function retrieve_secure_strings
has a Cognitive Complexity of 8 (exceeds 5 allowed). Consider refactoring. Open
Open
public function retrieve_secure_strings() {
$gateway_strings = $this->secure_strings;
foreach ( $this->get_admin_settings_fields() as $field ) {
- Read upRead up
Cognitive Complexity
Cognitive Complexity is a measure of how difficult a unit of code is to intuitively understand. Unlike Cyclomatic Complexity, which determines how difficult your code will be to test, Cognitive Complexity tells you how difficult your code will be to read and comprehend.
A method's cognitive complexity is based on a few simple rules:
- Code is not considered more complex when it uses shorthand that the language provides for collapsing multiple statements into one
- Code is considered more complex for each "break in the linear flow of the code"
- Code is considered more complex when "flow breaking structures are nested"