Showing 283 of 379 total issues
File bmh.php
has 252 lines of code (exceeds 250 allowed). Consider refactoring. Open
<?php
/**
* ****************************************************************************
* - A Project by Developers TEAM For Xoops - ( https://xoops.org )
* ****************************************************************************
Method getForm
has 50 lines of code (exceeds 25 allowed). Consider refactoring. Open
public function getForm($action = false, $system = 0)
{
global $xoopsDB;
if (false === $action) {
Method setLanguage
has 49 lines of code (exceeds 25 allowed). Consider refactoring. Open
public function setLanguage($langcode = 'en', $lang_path = '')
{
// Backwards compatibility for renamed language codes
$renamed_langcodes = [
'br' => 'pt_br',
Function xnewsletter_plugin_getdata_evennews
has a Cognitive Complexity of 15 (exceeds 5 allowed). Consider refactoring. Open
function xnewsletter_plugin_getdata_evennews($cat_id, $action_after_read, $limitcheck, $skipcatsubscrexist)
{
global $xoopsDB;
$helper = Xnewsletter\Helper::getInstance();
- 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 xnewsletter_plugin_getdata_rmbulletin
has a Cognitive Complexity of 15 (exceeds 5 allowed). Consider refactoring. Open
function xnewsletter_plugin_getdata_rmbulletin($cat_id, $action_after_read, $limitcheck, $skipcatsubscrexist)
{
global $xoopsDB;
$helper = Xnewsletter\Helper::getInstance();
- 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 xnewsletter_plugin_getdata_xoopsuser
has a Cognitive Complexity of 15 (exceeds 5 allowed). Consider refactoring. Open
function xnewsletter_plugin_getdata_xoopsuser(
$cat_id,
$action_after_read,
$limitCheck,
$skipCatsubscrExist,
- 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 xnewsletter_plugin_getdata_smartpartner
has a Cognitive Complexity of 15 (exceeds 5 allowed). Consider refactoring. Open
function xnewsletter_plugin_getdata_smartpartner($cat_id, $action_after_read, $limitcheck, $skipcatsubscrexist)
{
global $xoopsDB;
$helper = Xnewsletter\Helper::getInstance();
- 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 xnewsletter_plugin_getdata_weblinks
has a Cognitive Complexity of 15 (exceeds 5 allowed). Consider refactoring. Open
function xnewsletter_plugin_getdata_weblinks($cat_id, $action_after_read, $limitcheck, $skipcatsubscrexist)
{
global $xoopsDB;
$helper = Xnewsletter\Helper::getInstance();
- 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 xnewsletter_plugin_getdata_subscribers
has a Cognitive Complexity of 15 (exceeds 5 allowed). Consider refactoring. Open
function xnewsletter_plugin_getdata_subscribers($cat_id, $action_after_read, $limitcheck, $skipcatsubscrexist)
{
global $xoopsDB;
$helper = Xnewsletter\Helper::getInstance();
- 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 globalDelete
has a Cognitive Complexity of 15 (exceeds 5 allowed). Consider refactoring. Open
public function globalDelete()
{
$dateArr = explode('-', $this->deleteMsgDate); // date format is yyyy-mm-dd
$delDate = mktime(0, 0, 0, $dateArr[1], $dateArr[2], $dateArr[0]);
- 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
Method xnewsletter_plugin_getdata_xoopsuser
has 47 lines of code (exceeds 25 allowed). Consider refactoring. Open
function xnewsletter_plugin_getdata_xoopsuser(
$cat_id,
$action_after_read,
$limitCheck,
$skipCatsubscrExist,
Method xnewsletter_plugin_getdata_csv
has 47 lines of code (exceeds 25 allowed). Consider refactoring. Open
function xnewsletter_plugin_getdata_csv(
$cat_id,
$action_after_read,
$limitCheck,
$skipCatsubscrExist,
Method getForm
has 47 lines of code (exceeds 25 allowed). Consider refactoring. Open
public function getForm($action = false)
{
global $xoopsDB;
if (false === $action) {
Method xnewsletter_plugin_getdata_subscribers
has 46 lines of code (exceeds 25 allowed). Consider refactoring. Open
function xnewsletter_plugin_getdata_subscribers($cat_id, $action_after_read, $limitcheck, $skipcatsubscrexist)
{
global $xoopsDB;
$helper = Xnewsletter\Helper::getInstance();
Method msgHTML
has 46 lines of code (exceeds 25 allowed). Consider refactoring. Open
public function msgHTML($message, $basedir = '', $advanced = false)
{
preg_match_all('/(src|background)=["\'](.*)["\']/Ui', $message, $images);
if (array_key_exists(2, $images)) {
if (mb_strlen($basedir) > 1 && '/' != mb_substr($basedir, -1)) {
Method xnewsletter_plugin_getdata_evennews
has 46 lines of code (exceeds 25 allowed). Consider refactoring. Open
function xnewsletter_plugin_getdata_evennews($cat_id, $action_after_read, $limitcheck, $skipcatsubscrexist)
{
global $xoopsDB;
$helper = Xnewsletter\Helper::getInstance();
Method xnewsletter_plugin_getdata_smartpartner
has 46 lines of code (exceeds 25 allowed). Consider refactoring. Open
function xnewsletter_plugin_getdata_smartpartner($cat_id, $action_after_read, $limitcheck, $skipcatsubscrexist)
{
global $xoopsDB;
$helper = Xnewsletter\Helper::getInstance();
Method xnewsletter_plugin_getdata_weblinks
has 45 lines of code (exceeds 25 allowed). Consider refactoring. Open
function xnewsletter_plugin_getdata_weblinks($cat_id, $action_after_read, $limitcheck, $skipcatsubscrexist)
{
global $xoopsDB;
$helper = Xnewsletter\Helper::getInstance();
Method xnewsletter_plugin_getdata_rmbulletin
has 45 lines of code (exceeds 25 allowed). Consider refactoring. Open
function xnewsletter_plugin_getdata_rmbulletin($cat_id, $action_after_read, $limitcheck, $skipcatsubscrexist)
{
global $xoopsDB;
$helper = Xnewsletter\Helper::getInstance();
Method b_xnewsletter_catsubscr
has 45 lines of code (exceeds 25 allowed). Consider refactoring. Open
function b_xnewsletter_catsubscr($options)
{
global $xoopsUser;
$helper = Xnewsletter\Helper::getInstance();
$myts = \MyTextSanitizer::getInstance();