Showing 529 of 599 total issues
File MobileconfigSuperclass.php
has 531 lines of code (exceeds 250 allowed). Consider refactoring. Open
<?php
/*
* *****************************************************************************
* Contributions to this work were made on behalf of the GÉANT project, a
File Devices-template.php
has 530 lines of code (exceeds 250 allowed). Consider refactoring. Open
<?php
/*
* *****************************************************************************
* Contributions to this work were made on behalf of the GÉANT project, a
Function displayDeploymentPropertyWidget
has a Cognitive Complexity of 55 (exceeds 5 allowed). Consider refactoring. Open
function displayDeploymentPropertyWidget(&$deploymentObject) {
// RADIUS status icons
$radiusMessages = [
\core\AbstractDeployment::RADIUS_OK => ['icon' => '../resources/images/icons/Tabler/square-rounded-check-filled-green.svg', 'text' => _("Successfully set profile")],
\core\AbstractDeployment::RADIUS_FAILURE => ['icon' => '../resources/images/icons/Tabler/square-rounded-x-filled-red.svg', 'text' => _("Some problem occurred during profile update")],
- 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 prepareEapConfig
has a Cognitive Complexity of 54 (exceeds 5 allowed). Consider refactoring. Open
private function prepareEapConfig($attr)
{
$outerUser = '';
$vistaExt = '';
$w7Ext = '';
- 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
File RADIUSTestsUI.php
has 511 lines of code (exceeds 250 allowed). Consider refactoring. Open
<?php
/*
* *****************************************************************************
* Contributions to this work were made on behalf of the GÉANT project, a
Function prompt_nonempty_string
has a Cognitive Complexity of 53 (exceeds 5 allowed). Consider refactoring. Open
def prompt_nonempty_string(self, show: int, prompt: str, val: str = '') -> str:
"""
Prompt user for input
"""
if self.graphics == 'tty':
- 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 sanitiseInputs
has a Cognitive Complexity of 52 (exceeds 5 allowed). Consider refactoring. Open
private function sanitiseInputs(array $listOfEntries) {
$retval = [];
$bad = [];
$multilangAttrsWithC = [];
foreach ($listOfEntries as $objId => $objValueRaw) {
- 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 marshalObject
has a Cognitive Complexity of 50 (exceeds 5 allowed). Consider refactoring. Open
public static function marshalObject($domElement, $node, $name, $object, $namespace = NULL, $root = false)
{
if (is_null($object)) {
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
File CAT.php
has 489 lines of code (exceeds 250 allowed). Consider refactoring. Open
<?php
/*
* *****************************************************************************
* Contributions to this work were made on behalf of the GÉANT project, a
Method prepareEapConfig
has 193 lines of code (exceeds 25 allowed). Consider refactoring. Open
private function prepareEapConfig($attr)
{
$outerUser = '';
$vistaExt = '';
$w7Ext = '';
File diag_js.php
has 483 lines of code (exceeds 250 allowed). Consider refactoring. Open
<?php
/*
* *****************************************************************************
* Contributions to this work were made on behalf of the GÉANT project, a
File overview_federation.php
has 475 lines of code (exceeds 250 allowed). Consider refactoring. Open
<?php
/*
* *****************************************************************************
* Contributions to this work were made on behalf of the GÉANT project, a
* project that has received funding from the European Union’s Framework
Method htmlHeadCode
has 179 lines of code (exceeds 25 allowed). Consider refactoring. Open
public function htmlHeadCode() {
$cat = new \core\CAT();
\core\common\Entity::intoThePotatoes();
$retval = "
<link href='../external/OpenLayers/ol.css' rel='stylesheet' type='text/css'>
Function scrub
has a Cognitive Complexity of 45 (exceeds 5 allowed). Consider refactoring. Open
public function scrub($inputJson, $fedObject) {
$optionInstance = \core\Options::instance();
$parameters = [];
$allPossibleAttribs = array_merge(API::ACTIONS[$inputJson['ACTION']]['REQ'], API::ACTIONS[$inputJson['ACTION']]['OPT'], API::ACTIONS[$inputJson['ACTION']]['FLAG']);
// some actions don't need parameters. Don't get excited when there aren't any.
- 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
File DeviceXML.php
has 454 lines of code (exceeds 250 allowed). Consider refactoring. Open
<?php
/*
* *****************************************************************************
* Contributions to this work were made on behalf of the GÉANT project, a
Method displayRadiusPropertyWidget
has 172 lines of code (exceeds 25 allowed). Consider refactoring. Open
function displayRadiusPropertyWidget(&$theProfile, $readonly, &$uiElements, $editMode) {
?>
<div style='padding-bottom:20px;'>
<?php $profile_name = $theProfile->name; ?>
<div style='margin-bottom:10px; display:block;'>
Function displayRadiusPropertyWidget
has a Cognitive Complexity of 44 (exceeds 5 allowed). Consider refactoring. Open
function displayRadiusPropertyWidget(&$theProfile, $readonly, &$uiElements, $editMode) {
?>
<div style='padding-bottom:20px;'>
<?php $profile_name = $theProfile->name; ?>
<div style='margin-bottom:10px; display:block;'>
- 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 collectCAPath
has a Cognitive Complexity of 43 (exceeds 5 allowed). Consider refactoring. Open
private function collectCAPath()
{
$capathtest = [];
$capathtest[] = '<p><strong>'._("Checking server handshake...")."</strong><p>";
$allfailed = TRUE;
- 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
File UIElements.php
has 439 lines of code (exceeds 250 allowed). Consider refactoring. Open
<?php
/*
* *****************************************************************************
* Contributions to this work were made on behalf of the GÉANT project, a
File DeviceConfig.php
has 436 lines of code (exceeds 250 allowed). Consider refactoring. Open
<?php
/*
* *****************************************************************************
* Contributions to this work were made on behalf of the GÉANT project, a