Showing 228 of 247 total issues
Avoid too many return
statements within this method. Open
return $sql;
- Create a ticketCreate a ticket
Avoid too many return
statements within this method. Open
return $this;
- Create a ticketCreate a ticket
Avoid too many return
statements within this method. Open
return $matches[4] ?? $matches[2];
- Create a ticketCreate a ticket
Avoid too many return
statements within this method. Open
return $matches[2];
- Create a ticketCreate a ticket
Avoid too many return
statements within this method. Open
return $cmp;
- Create a ticketCreate a ticket
Avoid too many return
statements within this method. Open
return $matches[4] ?? $matches[2];
- Create a ticketCreate a ticket
Avoid too many return
statements within this method. Open
return $matches[2];
- Create a ticketCreate a ticket
Avoid too many return
statements within this method. Open
return $matches[0];
- Create a ticketCreate a ticket
Avoid too many return
statements within this method. Open
return $a <=> $b;
- Create a ticketCreate a ticket
Avoid too many return
statements within this method. Open
return 'object ' . print_r($value, true);
- Create a ticketCreate a ticket
Avoid too many return
statements within this method. Open
return $this->getOurModel()->addExpression($fieldName, array_merge($defaults, ['expr' => $fx]));
- Create a ticketCreate a ticket
Avoid too many return
statements within this method. Open
return $valueStr . ($title !== null ? ' (\'' . $title . '\')' : '');
- Create a ticketCreate a ticket
Avoid too many return
statements within this method. Open
return $convertedSql;
- Create a ticketCreate a ticket
Function afterLoad
has a Cognitive Complexity of 6 (exceeds 5 allowed). Consider refactoring. Open
#[\Override]
protected function afterLoad(Model $entity): void
{
$model = $this->getOwner();
- 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 initAction
has a Cognitive Complexity of 6 (exceeds 5 allowed). Consider refactoring. Open
public function initAction(Model $model, ?array $fields = null): Action
{
if (is_object($model->table)) {
$tableAction = $this->action($model->table, 'select');
- 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 tryLoad
has a Cognitive Complexity of 6 (exceeds 5 allowed). Consider refactoring. Open
#[\Override]
public function tryLoad(Model $model, $id): ?array
{
$model->assertIsModel();
- 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 getModelOnlyProperties
has a Cognitive Complexity of 6 (exceeds 5 allowed). Consider refactoring. Open
protected function getModelOnlyProperties(): array
{
$this->assertIsModel();
if ((self::$_modelOnlyProperties ?? null) === 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 getDsqlExpression
has a Cognitive Complexity of 6 (exceeds 5 allowed). Consider refactoring. Open
#[\Override]
public function getDsqlExpression(Expression $expression): Expression
{
$expr = $this->expr;
if ($expr instanceof \Closure) {
- 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 _renderWith
has a Cognitive Complexity of 6 (exceeds 5 allowed). Consider refactoring. Open
protected function _renderWith(): ?string
{
if (($this->args['with'] ?? []) === []) {
return '';
}
- 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"