Showing 552 of 784 total issues
Avoid too many return
statements within this function. Open
return sortInput ?
( indexOf( sortInput, a ) - indexOf( sortInput, b ) ) :
0;
Avoid too many return
statements within this function. Open
return false;
Avoid too many return
statements within this method. Open
return $this->jsResultReader($match[0] . $this->job->url->id . '/resultJS.json');
Avoid too many return
statements within this method. Open
return $this->socialMediaResultReader($match[0] . $this->job->url->id . '/resultSocmed.json');
Avoid too many return
statements within this method. Open
return $this->ySlowResultReader($match[0] . $this->job->url->id . '/resultYSlow.json');
Avoid too many return
statements within this function. Open
return select( selector.replace( rtrim, "$1" ), context, results, seed );
Avoid too many return
statements within this method. Open
return $this->gPagespeedResultReader($match[0] . $this->job->url->id . '/resultPagespeedDesktop.json');
Function check
has a Cognitive Complexity of 6 (exceeds 5 allowed). Consider refactoring. Open
function check(url) {
var Horseman = require('node-horseman'),
horseman = new Horseman();
- 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 needsClick
has a Cognitive Complexity of 6 (exceeds 5 allowed). Consider refactoring. Open
FastClick.prototype.needsClick = function(target) {
'use strict';
switch (target.nodeName.toLowerCase()) {
// Don't send a synthetic click to disabled inputs (issue #62)
- 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 generateJobByType
has a Cognitive Complexity of 6 (exceeds 5 allowed). Consider refactoring. Open
protected function generateJobByType($event, $type)
{
$urls = $event->project->urls()->active()->byType($type)->get();
$scopes = $this->generator->getByType($type);
foreach ($scopes as $scope) {
- 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 generateCommand
has a Cognitive Complexity of 6 (exceeds 5 allowed). Consider refactoring. Open
public function generateCommand($overallScopes, $name)
{
$scopeByName = $this->scope->getByName($name);
$overallScopes = (int)$overallScopes;
- 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 needsClick
has a Cognitive Complexity of 6 (exceeds 5 allowed). Consider refactoring. Open
FastClick.prototype.needsClick = function(target) {
'use strict';
switch (target.nodeName.toLowerCase()) {
// Don't send a synthetic click to disabled inputs (issue #62)
- 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"