removed duplicate code #5
2379 new problems found by Qodana for PHP
Qodana for PHP
2379 new problems were found
Inspection name | Severity | Problems |
---|---|---|
Undefined variable |
🔴 Failure | 5 |
Element is not available in configured PHP version |
🔴 Failure | 1 |
Strict type checking rules violation |
🔴 Failure | 1 |
Undefined class |
🔶 Warning | 204 |
Unreachable statement |
🔶 Warning | 166 |
Inconsistent return points |
🔶 Warning | 129 |
Undefined namespace |
🔶 Warning | 77 |
Undefined method |
🔶 Warning | 57 |
Parameter type |
🔶 Warning | 6 |
Undefined function |
🔶 Warning | 4 |
Redundant character escape |
🔶 Warning | 4 |
Duplicate case in switch statement |
🔶 Warning | 3 |
Type mismatch in property assignment |
🔶 Warning | 3 |
Incompatible return type |
🔶 Warning | 3 |
Parameter's name changed during inheritance |
🔶 Warning | 3 |
Statement has empty body |
🔶 Warning | 3 |
Missing parent call for constructor |
🔶 Warning | 1 |
Undefined property |
🔶 Warning | 1 |
Invalid function result used |
🔶 Warning | 1 |
Missing parameter's type declaration |
◽️ Notice | 410 |
Missing return type declaration |
◽️ Notice | 283 |
Return type in PHPDoc comment does not match the actual return type |
◽️ Notice | 204 |
Unhandled exception |
◽️ Notice | 139 |
Missing @throws tag(s) |
◽️ Notice | 128 |
Undefined variable |
◽️ Notice | 95 |
Missing property's type declaration |
◽️ Notice | 88 |
Unnecessary curly braces syntax for variable |
◽️ Notice | 64 |
Possible polymorphic call |
◽️ Notice | 55 |
Duplicated code fragment |
◽️ Notice | 43 |
Condition always evaluates to 'true/false' |
◽️ Notice | 33 |
'switch' can be replaced with 'match' expression |
◽️ Notice | 30 |
Unused parameter |
◽️ Notice | 18 |
PHPDoc comment matches function/method signature |
◽️ Notice | 17 |
Parameters number mismatch declaration |
◽️ Notice | 13 |
PHPDoc comment signature is not complete |
◽️ Notice | 10 |
Duplicate branch in switch statement |
◽️ Notice | 8 |
Fully qualified name usage |
◽️ Notice | 8 |
Deprecated |
◽️ Notice | 7 |
'switch' with single 'case' |
◽️ Notice | 7 |
Unused local variable |
◽️ Notice | 6 |
Unnecessary fully qualified name |
◽️ Notice | 5 |
Dynamic property declaration |
◽️ Notice | 4 |
Redundant optional argument |
◽️ Notice | 4 |
Extension is missing in composer.json |
◽️ Notice | 3 |
Define constant name can be replaced with 'const' syntax |
◽️ Notice | 3 |
Strict comparison of operands with incompatible types |
◽️ Notice | 3 |
Condition inside logical expression checked by subsequent condition |
◽️ Notice | 2 |
Non-installed Composer packages |
◽️ Notice | 2 |
Nullsafe operator '?->' can be used |
◽️ Notice | 2 |
Unnecessary local variable |
◽️ Notice | 2 |
Type tag without variable name |
◽️ Notice | 2 |
Type doesn't match property's declared type |
◽️ Notice | 1 |
'if' with common parts |
◽️ Notice | 1 |
Loop can be replaced with 'in_array()' or 'array_key_exists()' call |
◽️ Notice | 1 |
Missing 'break' statement |
◽️ Notice | 1 |
Non-strict object equality |
◽️ Notice | 1 |
Pointless boolean expression inside 'if' condition |
◽️ Notice | 1 |
Redundant assignment to promoted property |
◽️ Notice | 1 |
Redundant @var tag |
◽️ Notice | 1 |
Regular expression can be simplified |
◽️ Notice | 1 |
💡 Qodana analysis was run in the pull request mode: only the changed files were checked
☁️ View the detailed Qodana report
Contact Qodana team
Contact us at [email protected]
- Or via our issue tracker: https://jb.gg/qodana-issue
- Or share your feedback: https://jb.gg/qodana-discussions
Details
This result was published with Qodana GitHub Action
Annotations
Check notice on line 44 in src/Statements/Let/ExportSymbol.php
github-actions / Qodana for PHP
Duplicated code fragment
Duplicated code
Check notice on line 46 in src/Operators/Other/ShortTernaryOperator.php
github-actions / Qodana for PHP
Duplicated code fragment
Duplicated code
Check notice on line 42 in src/Optimizers/FunctionCall/BasenameOptimizer.php
github-actions / Qodana for PHP
Duplicated code fragment
Duplicated code
Check notice on line 110 in src/Detectors/WriteDetector.php
github-actions / Qodana for PHP
Duplicated code fragment
Duplicated code
Check notice on line 53 in src/Optimizers/FunctionCall/CreateInstanceOptimizer.php
github-actions / Qodana for PHP
Duplicated code fragment
Duplicated code
Check notice on line 38 in src/Operators/Arithmetical/DivOperator.php
github-actions / Qodana for PHP
Duplicated code fragment
Duplicated code
Check notice on line 324 in src/Detectors/WriteDetector.php
github-actions / Qodana for PHP
Duplicated code fragment
Duplicated code
Check notice on line 600 in src/Operators/Arithmetical/ArithmeticalBaseOperator.php
github-actions / Qodana for PHP
Duplicated code fragment
Duplicated code
Check notice on line 184 in src/CompilerFile.php
github-actions / Qodana for PHP
Duplicated code fragment
Duplicated code
Check notice on line 42 in src/Optimizers/FunctionCall/BasenameOptimizer.php
github-actions / Qodana for PHP
Duplicated code fragment
Duplicated code
Check notice on line 176 in src/Expression/NativeArrayAccess.php
github-actions / Qodana for PHP
Duplicated code fragment
Duplicated code
Check notice on line 42 in src/Optimizers/FunctionCall/Crc32Optimizer.php
github-actions / Qodana for PHP
Duplicated code fragment
Duplicated code
Check notice on line 116 in src/Expression/Closure.php
github-actions / Qodana for PHP
Duplicated code fragment
Duplicated code
Check notice on line 352 in src/Detectors/WriteDetector.php
github-actions / Qodana for PHP
Duplicated code fragment
Duplicated code
Check notice on line 69 in src/Statements/Let/ObjectPropertyAppend.php
github-actions / Qodana for PHP
Duplicated code fragment
Duplicated code
Check notice on line 770 in src/MethodCall.php
github-actions / Qodana for PHP
Duplicated code fragment
Duplicated code
Check notice on line 380 in src/Detectors/WriteDetector.php
github-actions / Qodana for PHP
Duplicated code fragment
Duplicated code
Check notice on line 42 in src/Optimizers/FunctionCall/Md5Optimizer.php
github-actions / Qodana for PHP
Duplicated code fragment
Duplicated code
Check notice on line 83 in src/Cache/MethodCache.php
github-actions / Qodana for PHP
Duplicated code fragment
Duplicated code
Check notice on line 42 in src/Optimizers/FunctionCall/FilePutContentsOptimizer.php
github-actions / Qodana for PHP
Duplicated code fragment
Duplicated code
Check notice on line 311 in src/Operators/Arithmetical/DivOperator.php
github-actions / Qodana for PHP
Duplicated code fragment
Duplicated code
Check notice on line 47 in src/Optimizers/FunctionCall/VarDumpOptimizer.php
github-actions / Qodana for PHP
Duplicated code fragment
Duplicated code
Check notice on line 595 in src/Operators/Arithmetical/DivOperator.php
github-actions / Qodana for PHP
Duplicated code fragment
Duplicated code
Check notice on line 595 in src/Operators/Arithmetical/DivOperator.php
github-actions / Qodana for PHP
Duplicated code fragment
Duplicated code
Check notice on line 283 in src/Statements/Let/ObjectProperty.php
github-actions / Qodana for PHP
Duplicated code fragment
Duplicated code