fannie/modules/plugins2.0/HrWeb/Screening/ScreeningPage.php
Method post_view
has 114 lines of code (exceeds 25 allowed). Consider refactoring. Open
Open
protected function post_view()
{
$empID = FormLib::get('lookup', -1);
$dbc = FannieDB::get($this->config->get('OP_DB'));
File ScreeningPage.php
has 354 lines of code (exceeds 250 allowed). Consider refactoring. Open
Open
<?php
include(__DIR__ . '/../../../../config.php');
if (!class_exists('FannieAPI')) {
include(__DIR__ . '/../../../../classlib2.0/FannieAPI.php');
Method get_view
has 98 lines of code (exceeds 25 allowed). Consider refactoring. Open
Open
protected function get_view()
{
$dbc = FannieDB::get($this->config->get('OP_DB'));
$nonce = uniqid('', true);
$setP = $dbc->prepare("UPDATE " . FannieDB::fqn('ScreeningNonce', 'plugin:HrWebDB') . " SET nonce=?");
Method post_id_view
has 59 lines of code (exceeds 25 allowed). Consider refactoring. Open
Open
protected function post_id_view()
{
$dbc = FannieDB::get($this->config->get('OP_DB'));
$any = FormLib::get('any') ? 1 : 0;
Function post_id_view
has a Cognitive Complexity of 8 (exceeds 5 allowed). Consider refactoring. Open
Open
protected function post_id_view()
{
$dbc = FannieDB::get($this->config->get('OP_DB'));
$any = FormLib::get('any') ? 1 : 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"