Showing 1,086 of 1,086 total issues
Avoid too many return
statements within this method. Open
Open
return $gem->config();
Avoid too many return
statements within this method. Open
Open
return $this->config;
Avoid too many return
statements within this method. Open
Open
return $this;
Avoid too many return
statements within this method. Open
Open
return fn(...$argv) => $this->resolve($gem->config(), $this->vars($this->variadic($argv), $gem->args()));
Avoid too many return
statements within this method. Open
Open
return ($this->provider() ?? new Unresolvable)($gem->config(), $this->vars($args, $gem->args()));
Avoid too many return
statements within this method. Open
Open
return $this->shared($gem->name(), $gem->config(), $args);
Avoid too many return
statements within this method. Open
Open
return (new class() {
function __invoke($file) {
return include $file;
}
})($this->resolve($gem->config()));
Avoid too many return
statements within this method. Open
Open
return $this->resolve($gem->exception(), $gem->args($exception, $args));
Avoid too many return
statements within this method. Open
Open
return Unresolvable::plugin($gem);
Function has
has a Cognitive Complexity of 6 (exceeds 5 allowed). Consider refactoring. Open
Open
function has($name) : bool
{
if (is_string($name)) {
return isset($this->container[$name]) || isset($this->services[$name]);
}
- 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
Possibly zero references to global constant \Mvc5\CALL_SEPARATOR
Open
Open
const CALL_SEPARATOR = '.';
- Exclude checks
Possibly zero references to global constant \Mvc5\EVENTS
Open
Open
const EVENTS = 'events';
- Exclude checks
Possibly zero references to global constant \Mvc5\INDEX
Open
Open
const INDEX = '#';
- Exclude checks
Possibly zero references to global constant \Mvc5\SAMESITE
Open
Open
const SAMESITE = 'samesite';
- Exclude checks
non-abstract class \Mvc5\App
contains abstract internal method \Iterator::key
Open
Open
class App
- Exclude checks
non-abstract class \Mvc5\ArrayObject
contains abstract internal method \Countable::count
Open
Open
class ArrayObject
- Exclude checks
non-abstract class \Mvc5\ArrayObject
contains abstract internal method \Iterator::rewind
Open
Open
class ArrayObject
- Exclude checks
Return type of offsetGet()
is undeclared type \Mvc5\Config\mixed
Open
Open
function offsetGet($name) : mixed
- Exclude checks
syntax error, unexpected 'array' (T_ARRAY), expecting function (T_FUNCTION) or const (T_CONST)
Open
Open
protected array $config = [];
- Exclude checks
Doc-block of without
contains declared return type mixed
which is incompatible with the return type \Mvc5\Config\Model
declared in the signature Open
Open
* @return Model|mixed
- Exclude checks