Showing 701 of 9,653 total issues
Function _initKeys
has 28 lines of code (exceeds 25 allowed). Consider refactoring. Open
function _initKeys( $wrpr, opts )
{
if ( opts.prev.key || opts.next.key || opts.close.key )
{
$(document).bind(
Method extgallery_tag_iteminfo
has 28 lines of code (exceeds 25 allowed). Consider refactoring. Open
function extgallery_tag_iteminfo(&$items)
{
if (empty($items) || !is_array($items)) {
return false;
}
Method staticPushErrorHandling
has 28 lines of code (exceeds 25 allowed). Consider refactoring. Open
public static function staticPushErrorHandling($mode, $options = null)
{
$stack = &$GLOBALS['_PEAR_error_handler_stack'];
$def_mode = &$GLOBALS['_PEAR_default_error_mode'];
$def_options = &$GLOBALS['_PEAR_default_error_options'];
Method get_image_url
has 28 lines of code (exceeds 25 allowed). Consider refactoring. Open
public function get_image_url()
{
// Get the image file path
if (!mb_strlen($this->path)) {
return $this->url;
Method _dirToStruct
has 28 lines of code (exceeds 25 allowed). Consider refactoring. Open
protected static function _dirToStruct($sPath, $maxinst, $aktinst = 0, $silent = false)
{
$struct = ['dirs' => [], 'files' => []];
if (false === ($dir = @opendir($sPath))) {
if (!$silent) {
Method rotate
has 28 lines of code (exceeds 25 allowed). Consider refactoring. Open
public function rotate($angle, $options = null)
{
if (!($angle == $this->_rotation_angle($angle))) {
// No rotation needed
return true;
Method PclTarDelete
has 28 lines of code (exceeds 25 allowed). Consider refactoring. Open
function PclTarDelete($p_tarname, $p_filelist, $p_mode = '')
{
TrFctStart(__FILE__, __LINE__, 'PclTarDelete', "tar='$p_tarname', list='$p_filelist', mode='$p_mode'");
$v_result = 1;
Method PclTarExtractList
has 28 lines of code (exceeds 25 allowed). Consider refactoring. Open
function PclTarExtractList($p_tarname, $p_filelist, $p_path = './', $p_remove_path = '', $p_mode = '')
{
TrFctStart(__FILE__, __LINE__, 'PclTarExtractList', "tar=$p_tarname, list, path=$p_path, remove_path='$p_remove_path', mode='$p_mode'");
$v_result = 1;
Method PclTarUpdate
has 28 lines of code (exceeds 25 allowed). Consider refactoring. Open
function PclTarUpdate($p_tarname, $p_filelist, $p_mode = '', $p_add_dir = '', $p_remove_dir = '')
{
TrFctStart(__FILE__, __LINE__, 'PclTarUpdate', "tar='$p_tarname', list='$p_filelist', mode='$p_mode'");
$v_result = 1;
Method getMax
has 28 lines of code (exceeds 25 allowed). Consider refactoring. Open
public function getMax(\CriteriaElement $criteria = null, $max = '*')
{
$field = '';
$groupby = false;
if (\is_object($criteria) && \is_subclass_of($criteria, \CriteriaElement::class)) {
Method render
has 28 lines of code (exceeds 25 allowed). Consider refactoring. Open
public function render()
{
$ele_name = $this->getName();
echo '<table class="outer"><tr><td class="odd"><table><tr>';
$cols = 1;
Method getSum
has 28 lines of code (exceeds 25 allowed). Consider refactoring. Open
public function getSum(\CriteriaElement $criteria = null, $sum = '*')
{
$field = '';
$groupby = false;
if (\is_object($criteria) && \is_subclass_of($criteria, \CriteriaElement::class)) {
Function checkWpFooter
has a Cognitive Complexity of 10 (exceeds 5 allowed). Consider refactoring. Open
private function checkWpFooter()
{
$current_theme = wp_get_theme();
$theme_name = $current_theme->Template;
- 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"
Further reading
Function convertorderbytrans
has a Cognitive Complexity of 10 (exceeds 5 allowed). Consider refactoring. Open
function convertorderbytrans($SortbyOrderby)
{
$orderbyTrans = [];
if ('photo_date DESC' === $SortbyOrderby) {
$orderbyTrans = _MD_EXTGALLERY_ORDERBY_DATEASC;
- 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"
Further reading
Function ajax_create_slide
has a Cognitive Complexity of 10 (exceeds 5 allowed). Consider refactoring. Open
public function ajax_create_slide()
{
// security check
if (!wp_verify_nonce($_REQUEST['_wpnonce'], 'metaslider_addslide')) {
echo "<tr><td colspan='2'>" . __('Security check failed. Refresh page and try again.', 'metaslider') . '</td></tr>';
- 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"
Further reading
Function convertorderbytrans
has a Cognitive Complexity of 10 (exceeds 5 allowed). Consider refactoring. Open
function convertorderbytrans($SortbyOrderby)
{
$orderbyTrans = [];
if ('photo_date DESC' === $SortbyOrderby) {
$orderbyTrans = _MD_EXTGALLERY_ORDERBY_DATEASC;
- 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"
Further reading
Function tmpdir
has a Cognitive Complexity of 10 (exceeds 5 allowed). Consider refactoring. Open
public static function tmpdir()
{
if (OS_WINDOWS) {
if ($var = $_ENV['TMP'] ?? getenv('TMP')) {
return $var;
- 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"
Further reading
Function getSum
has a Cognitive Complexity of 10 (exceeds 5 allowed). Consider refactoring. Open
public function getSum(\CriteriaElement $criteria = null, $sum = '*')
{
$field = '';
$groupby = false;
if (\is_object($criteria) && \is_subclass_of($criteria, \CriteriaElement::class)) {
- 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"
Further reading
Function _makeWatermark
has a Cognitive Complexity of 10 (exceeds 5 allowed). Consider refactoring. Open
public function _makeWatermark($imageTransform)
{
if (!\function_exists('imagettfbbox')) {
return;
}
- 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"
Further reading
Function getMax
has a Cognitive Complexity of 10 (exceeds 5 allowed). Consider refactoring. Open
public function getMax(\CriteriaElement $criteria = null, $max = '*')
{
$field = '';
$groupby = false;
if (\is_object($criteria) && \is_subclass_of($criteria, \CriteriaElement::class)) {
- 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"