Showing 379 of 6,675 total issues
Student
has 33 functions (exceeds 20 allowed). Consider refactoring. Open
class Student {
// Defines for Internship Inventory student Data
const MAIN_CAMPUS = 'main_campus';
const DISTANCE_ED = 'distance_ed';
- Create a ticketCreate a ticket
Method getCSV
has 104 lines of code (exceeds 25 allowed). Consider refactoring. Open
public function getCSV()
{
// Initalize term description list, if needed
// Store term list in a static var, so hopefully we only do this once per export
if(!isset(self::$termDescriptionList)){
- Create a ticketCreate a ticket
Method buildMessage
has 104 lines of code (exceeds 25 allowed). Consider refactoring. Open
protected function buildMessage()
{
$subjects = Subject::getSubjects();
$faculty = $this->internship->getFaculty();
- Create a ticketCreate a ticket
Function render
has 103 lines of code (exceeds 25 allowed). Consider refactoring. Open
render() {
var censusCalendar = null;
var availableCalendar = null;
var startCalendar = null;
- Create a ticketCreate a ticket
Function execute
has a Cognitive Complexity of 26 (exceeds 5 allowed). Consider refactoring. Open
public function execute()
{
// Get the list of future terms
$terms = TermFactory::getFutureTermsAssoc();
- Read upRead up
- Create a ticketCreate a ticket
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 plugStudentValues
has a Cognitive Complexity of 26 (exceeds 5 allowed). Consider refactoring. Open
protected function plugStudentValues(&$student, \stdClass $data){
/**********************
* Basic Demographics *
**********************/
$student->setStudentId($data->bannerID);
- Read upRead up
- Create a ticketCreate a ticket
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 getSortButtons
has a Cognitive Complexity of 26 (exceeds 5 allowed). Consider refactoring. Open
public function getSortButtons(&$template)
{
if (empty($this->table_columns)) {
return null;
}
- Read upRead up
- Create a ticketCreate a ticket
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 import
has a Cognitive Complexity of 26 (exceeds 5 allowed). Consider refactoring. Open
public static function import($text, $report_errors = true)
{
PHPWS_DB::touchDB();
// first_import makes sure at least one query was completed
- Read upRead up
- Create a ticketCreate a ticket
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 getJoin
has a Cognitive Complexity of 26 (exceeds 5 allowed). Consider refactoring. Open
public function getJoin()
{
if (empty($this->_join_tables)) {
return null;
}
- Read upRead up
- Create a ticketCreate a ticket
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 render
has 91 lines of code (exceeds 25 allowed). Consider refactoring. Open
render() {
var AdminsData = null;
if (this.state.mainData != null) {
var onAdminDelete = this.onAdminDelete;
AdminsData = this.state.displayData.map(function (admin) {
- Create a ticketCreate a ticket
File otherGoodies.js
has 317 lines of code (exceeds 250 allowed). Consider refactoring. Open
/***********************
* Form Save Handler
* Prevents duplicate form submission.
*/
function setupFormSubmit()
- Create a ticketCreate a ticket
Method addWhere
has 89 lines of code (exceeds 25 allowed). Consider refactoring. Open
public function addWhere($column, $value = null, $operator = null, $conj = null, $group = null, $join = false)
{
PHPWS_DB::touchDB();
$where = new PHPWS_DB_Where;
- Create a ticketCreate a ticket
Method nickname
has 87 lines of code (exceeds 25 allowed). Consider refactoring. Open
function nickname($first_name)
{
$shortened = array(
'Abigail' => 'Abby',
'Alexander' => 'Alex',
- Create a ticketCreate a ticket
Function checkForMissingInput
has a Cognitive Complexity of 24 (exceeds 5 allowed). Consider refactoring. Open
private function checkForMissingInput() {
// Check for missing data
$missingFieldList = array();
// Check student ID
- Read upRead up
- Create a ticketCreate a ticket
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 buildMessage
has a Cognitive Complexity of 24 (exceeds 5 allowed). Consider refactoring. Open
protected function buildMessage()
{
$subjects = Subject::getSubjects();
$faculty = $this->internship->getFaculty();
- Read upRead up
- Create a ticketCreate a ticket
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 render
has 83 lines of code (exceeds 25 allowed). Consider refactoring. Open
render() {
if(this.state.data === null){
return (<div></div>);
}
- Create a ticketCreate a ticket
Method select
has 83 lines of code (exceeds 25 allowed). Consider refactoring. Open
public function select($type = null, $sql = null)
{
if (empty($sql)) {
if (!empty($this->sql)) {
$sql = & $this->sql;
- Create a ticketCreate a ticket
Method display
has 82 lines of code (exceeds 25 allowed). Consider refactoring. Open
public function display()
{
javascript('jquery');
\Layout::addPageTitle('Search Results');
- Create a ticketCreate a ticket
Function display
has a Cognitive Complexity of 23 (exceeds 5 allowed). Consider refactoring. Open
public function display()
{
javascript('jquery');
\Layout::addPageTitle('Search Results');
- Read upRead up
- Create a ticketCreate a ticket
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 _indexBy
has a Cognitive Complexity of 23 (exceeds 5 allowed). Consider refactoring. Open
public function _indexBy($sql, $indexby, $colMode = false)
{
$rows = array();
if (!is_array($sql) || empty($sql)) {
- Read upRead up
- Create a ticketCreate a ticket
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"