Showing 1,511 of 31,793 total issues
Method load_graph_definitions
has 1568 lines of code (exceeds 25 allowed). Consider refactoring. Open
Open
function load_graph_definitions($logarithmic = false, $tinylegend = false)
{
global $GraphDefs, $MetaGraphDefs;
$Canvas = 'FFFFFF';
File api_functions.inc.php
has 2688 lines of code (exceeds 250 allowed). Consider refactoring. Open
Open
<?php
/*
* LibreNMS
*
File definitions.php
has 1971 lines of code (exceeds 250 allowed). Consider refactoring. Open
Open
<?php
// vim:fenc=utf-8:filetype=php:ts=4
/*
* Copyright (C) 2009 Bruno Prémont <bonbons AT linux-vserver.org>
File settings.php
has 1775 lines of code (exceeds 250 allowed). Consider refactoring. Open
Open
<?php
return [
'title' => 'Settings',
'readonly' => 'Set in config.php, remove from config.php to enable.',
File settings.php
has 1598 lines of code (exceeds 250 allowed). Consider refactoring. Open
Open
<?php
return [
'title' => 'Settings',
'readonly' => 'Set in config.php, remove from config.php to enable.',
File settings.php
has 1581 lines of code (exceeds 250 allowed). Consider refactoring. Open
Open
<?php
return [
'title' => 'Налаштування',
'readonly' => 'Зазначено у config.php, для увімкнення видаліть з config.php.',
Method rewriteHardware
has 605 lines of code (exceeds 25 allowed). Consider refactoring. Open
Open
private function rewriteHardware()
{
$rewrite_ironware_hardware = [
'snFIWGSwitch' => 'Stackable FastIron workgroup',
'snFIBBSwitch' => 'Stackable FastIron backbone',
File settings.php
has 1149 lines of code (exceeds 250 allowed). Consider refactoring. Open
Open
<?php
return [
'readonly' => 'Dejà configuré dans config.php, le supprimer avant de pouvoir l\'éditer ici',
'groups' => [
File functions.inc.php
has 1131 lines of code (exceeds 250 allowed). Consider refactoring. Open
Open
<?php
/*
* LibreNMS Network Management and Monitoring System
* Copyright (C) 2006-2011, Observium Developers - http://www.observium.org
File custom-edit.blade.php
has 1061 lines of code (exceeds 250 allowed). Consider refactoring. Open
Open
@extends('layouts.librenmsv1')
@section('title', __('map.custom.title.edit'))
@section('content')
File settings.php
has 1018 lines of code (exceeds 250 allowed). Consider refactoring. Open
Open
<?php
return [
'readonly' => '在 config.php 裡被設定成唯讀,請由 config.php 移除它來啟用。',
'groups' => [
Function discovery_process
has a Cognitive Complexity of 126 (exceeds 5 allowed). Consider refactoring. Open
Open
function discovery_process(&$valid, $os, $sensor_class, $pre_cache)
{
$discovery = $os->getDiscovery('sensors');
$device = $os->getDeviceArray();
- 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
Device
has 121 functions (exceeds 20 allowed). Consider refactoring. Open
Open
class Device extends BaseModel
{
use PivotEventTrait, HasFactory;
public $timestamps = false;
File cape.inc.php
has 943 lines of code (exceeds 250 allowed). Consider refactoring. Open
Open
<?php
use LibreNMS\Exceptions\JsonAppException;
use LibreNMS\RRD\RrdDefinition;
Function command_runner
has a Cognitive Complexity of 113 (exceeds 5 allowed). Consider refactoring. Open
Open
def command_runner(
command, # type: Union[str, List[str]]
valid_exit_codes=None, # type: Optional[List[int]]
timeout=3600, # type: Optional[int]
shell=False, # type: bool
- 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 functions.inc.php
has 891 lines of code (exceeds 250 allowed). Consider refactoring. Open
Open
<?php
/**
* LibreNMS
*
File IRCBot.php
has 824 lines of code (exceeds 250 allowed). Consider refactoring. Open
Open
<?php
/*
* Copyright (C) 2014 <singh@devilcode.org>
* Modified and Relicensed by <f0o@devilcode.org> under the expressed
* permission by the Copyright-Holder <singh@devilcode.org>.
File settings.php
has 822 lines of code (exceeds 250 allowed). Consider refactoring. Open
Open
<?php
return [
'readonly' => '在 config.php 里被设定成只读,请由 config.php 移除它来启用。',
'groups' => [
File settings.php
has 808 lines of code (exceeds 250 allowed). Consider refactoring. Open
Open
<?php
return [
'readonly' => 'Ist in config.php konfiguriert. Zur Aktivierung entfernen Sie den Eintrag aus der config.php.',
'groups' => [
File Device.php
has 803 lines of code (exceeds 250 allowed). Consider refactoring. Open
Open
<?php
namespace App\Models;
use App\View\SimpleTemplate;