-
Notifications
You must be signed in to change notification settings - Fork 621
Adjustments related to PHP 8.x - Part 1 #399
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Open
DanProgs
wants to merge
93
commits into
TestLinkOpenSourceTRMS:testlink_1_9_20_fixed
Choose a base branch
from
DanProgs:changes-part-1
base: testlink_1_9_20_fixed
Could not load branches
Branch not found: {{ refName }}
Loading
Could not load tags
Nothing to show
Loading
Are you sure you want to change the base?
Some commits from the old base branch may be removed from the timeline,
and old review comments may become outdated.
Open
Adjustments related to PHP 8.x - Part 1 #399
DanProgs
wants to merge
93
commits into
TestLinkOpenSourceTRMS:testlink_1_9_20_fixed
from
DanProgs:changes-part-1
Conversation
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
codeplex-phpexcel-1.7.6
The following adjustments were made: - Files should end with a newline (PHP:S113) - Sections of code should not be commented out (PHP:S125) - Mergeable "if" statements should be combined (PHP:S1066) - Lines should not end with trailing whitespaces (PHP:S1131) - Unused local variables should be removed (PHP:S1481) - Identical expressions should not be used on both sides of a binary operator (PHP:S1764) - PHP keywords and constants "true", "false", "null" should be lower case (PHP:S1781) - "elseif" keyword should be used in place of "else if" keywords (PHP:S1793) - Unused assignments should be removed (PHP:S1854)
The following adjustments were made: - Files should end with a newline (PHP:S113) - Mergeable "if" statements should be combined (PHP:S1066) - Empty statements should be removed (PHP:S1116) - Lines should not end with trailing whitespaces (PHP:S1131) - Unused function parameters should be removed (PHP:S1172) - "elseif" keyword should be used in place of "else if" keywords (PHP:S1793) - Unused assignments should be removed (PHP:S1854) - Two branches in a conditional structure should not have exactly the same implementation (PHP:S1871) - Array values should not be replaced unconditionally (PHP:S4143)
The following adjustments were made: - Files should end with a newline (PHP:S113) - Sections of code should not be commented out (PHP:S125) - Identical expressions should not be used on both sides of a binary operator (PHP:S1764) - PHP keywords and constants "true", "false", "null" should be lower case (PHP:S1781) - "elseif" keyword should be used in place of "else if" keywords (PHP:S1793) - Two branches in a conditional structure should not have exactly the same implementation (PHP:S1871) - Array values should not be replaced unconditionally (PHP:S4143)
The following adjustments were made: - Files should end with a newline (PHP:S113) - Unused local variables should be removed (PHP:S1481) - PHP keywords and constants "true", "false", "null" should be lower case (PHP:S1781)
The following adjustments were made: - Files should end with a newline (PHP:S113) - Mergeable "if" statements should be combined (PHP:S1066) - Redundant pairs of parentheses should be removed (PHP:1110) - Unused function parameters should be removed (PHP:S1172) - Unused local variables should be removed (PHP:S1481) - The "var" keyword should not be used (PHP:S1765) - PHP keywords and constants "true", "false", "null" should be lower case (PHP:S1781)
The following adjustments were made: - Files should end with a newline (PHP:S113) - Control structures should use curly braces (PHP:S121) - Non-empty statements should change control flow or have at least one side-effect (PHP:S905) - Mergeable "if" statements should be combined (PHP:S1066) - Unused "private" fields should be removed (PHP:S1068) - Redundant pairs of parentheses should be removed (PHP:1110) - Empty statements should be removed (PHP:S1116) - The "var" keyword should not be used (PHP:S1765)
The following adjustments were made: - Files should end with a newline (PHP:S113) - Empty statements should be removed (PHP:S1116) - Boolean literals should not be redundant (PHP:S1125) - "elseif" keyword should be used in place of "else if" keywords (PHP:S1793) - Unused assignments should be removed (PHP:S1854) - Unused local variables should be removed (PHP:S1481)
- Files should end with a newline (PHP:S113) - Empty statements should be removed (PHP:S1116) - Boolean literals should not be redundant (PHP:S1125) - Lines should not end with trailing whitespaces (PHP:S1131) - PHP keywords and constants "true", "false", "null" should be lower case (PHP:S1781) - "elseif" keyword should be used in place of "else if" keywords (PHP:S1793)
The following adjustments were made: - Files should end with a newline (PHP:S113) - Mergeable "if" statements should be combined (PHP:S1066) - Empty statements should be removed (PHP:S1116) - Boolean literals should not be redundant (PHP:S1125) - Lines should not end with trailing whitespaces (PHP:S1131) - "empty()" should be used to test for emptiness (PHP:S1155) - Unused function parameters should be removed (PHP:S1172) - Unused local variables should be removed (PHP:S1481) - "elseif" keyword should be used in place of "else if" keywords (PHP:S1793) - Unused assignments should be removed (PHP:S1854) - "require_once" and "include_once" should be used instead of "require" and "include" (PHP:S2003)
The following adjustments were made: - Files should end with a newline (PHP:S113) - Control structures should use curly braces (PHP:S121) - Empty statements should be removed (PHP:S1116) - Unused function parameters should be removed (PHP:S1172) - Unused local variables should be removed (PHP:S1481) - "elseif" keyword should be used in place of "else if" keywords (PHP:S1793) - "require_once" and "include_once" should be used instead of "require" and "include" (PHP:S2003) - Unnecessary parentheses should not be used for constructs (PHP:S6600)
The following adjustments were made: - Revision of the parentheses for csv output
The following adjustments were made: - Files should end with a newline (PHP:S113) - Sections of code should not be commented out (PHP:S125) - Boolean literals should not be redundant (PHP:S1125) - Lines should not end with trailing whitespaces (PHP:S1131) - Unused local variables should be removed (PHP:S1481) - "elseif" keyword should be used in place of "else if" keywords (PHP:S1793)
The following adjustments were made: - Formate source code - Remove trailing whitespaces - Files should end with a newline (PHP:S113) - Control structures should use curly braces (PHP:S121) - Sections of code should not be commented out (PHP:S125) - Mergeable "if" statements should be combined (PHP:S1066) - Empty statements should be removed (PHP:S1116) - Modifiers should be declared in the correct order (PHP:S1124) - Boolean literals should not be redundant (PHP:S1125) - Use empty() to check whether the array is empty or not (PHP:S1155) - Unused function parameters should be removed (PHP:S1172) - Unused local variables should be removed (PHP:S1481) - Local variables should not be declared and then immediately returned or thrown (PHP:1488) - Method visibility should be explicitly declared (PHP:S1784) - The "var" keyword should not be used (PHP:S1765) - PHP keywords and constants "true", "false", "null" should be lower case (PHP:S1781) - "elseif" keyword should be used in place of "else if" keywords (PHP:S1793) - Unused assignments should be removed (PHP:S1854) - Jump statements should not be redundant (PHP:3626)
The following adjustments were made: - Formate source code - Control structures should use curly braces (PHP:S121) - Mergeable "if" statements should be combined (PHP:S1066) - Redundant pairs of parentheses should be removed (PHP:1110) - Boolean literals should not be redundant (PHP:S1125) - Return of boolean expressions should not be wrapped into an "if-then-else" statement (PHP:S1126) - Use empty() to check whether the array is empty or not (PHP:S1155) - Unused local variables should be removed (PHP:S1481) - Local variables should not be declared and then immediately returned or thrown (PHP:1488) - "elseif" keyword should be used in place of "else if" keywords (PHP:S1793) - Unused assignments should be removed (PHP:S1854) - "&&" and "||" should be used (PHP:S2010) - Unnecessary parentheses should not be used for constructs (PHP:S6600)
The following adjustments were made: - Formate source code - Files should end with a newline (PHP:S113) - Control structures should use curly braces (PHP:S121) - Sections of code should not be commented out (PHP:S125) - Mergeable "if" statements should be combined (PHP:S1066) - Empty statements should be removed (PHP:S1116) - Boolean literals should not be redundant (PHP:S1125) - Lines should not end with trailing whitespaces (PHP:S1131) - Use empty() to check whether the array is empty or not (PHP:S1155) - Unused local variables should be removed (PHP:S1481) - Local variables should not be declared and then immediately returned or thrown (PHP:1488) - Deprecated constructor declarations should not be used (PHP:S1603) - PHP keywords and constants "true", "false", "null" should be lower case (PHP:S1781) - "require_once" and "include_once" should be used instead of "require" and "include" (PHP:S2003) - Unnecessary parentheses should not be used for constructs (PHP:S6600)
The following adjustments were made: - Control structures should use curly braces (PHP:S121) - Mergeable "if" statements should be combined (PHP:S1066) - Redundant pairs of parentheses should be removed (PHP:1110) - Unused local variables should be removed (PHP:S1481) - Local variables should not be declared and then immediately returned or thrown (PHP:S1488) - PHP keywords and constants "true", "false", "null" should be lower case (PHP:S1781) - Unused assignments should be removed (PHP:S1854) - The "print" statement should not be used (python:PrintStatementUsage)
The following adjustments were made: - Permissions adjusted
The following adjustments were made: - Formate source code - Permissions revised - Sections of code should not be commented out (PHP:S125) - Mergeable "if" statements should be combined (PHP:S1066) - Unused local variables should be removed (PHP:S1481) - Local variables should not be declared and then immediately returned or thrown (PHP:1488) - Identical expressions should not be used on both sides of a binary operator (PHP:S1764) - Attributes deprecated in HTML5 should not be used (PHP:S1827) - Unused assignments should be removed (PHP:S1854) - "default" clauses should be first or last (PHP:4524)
The following adjustments were made: - Formate source code - Permissions revised - Local variable and function parameter names should comply with a naming convention (PHP:117) - Unused function parameters should be removed (PHP:S1172)
The following adjustments were made: - Formate source code - Permissions revised - Minor corrections - Switch cases should end with an unconditional "break" statement (PHP:128) - "switch" statements should have "default" clauses (PHP:131) - "switch" statements should have at least 3 "case" clauses (PHP:1301)
8cad7fe to
a2d7031
Compare
Applied rules: * RemoveUnusedForeachKeyRector * VarToPublicPropertyRector
* ExplicitPublicClassMethodRector * CountArrayToEmptyArrayComparisonRector
* DisallowedEmptyRuleFixerRector * RemoveUnusedNonEmptyArrayBeforeForeachRector
* ExplicitBoolCompareRector * TernaryToBooleanOrFalseToBooleanAndRector
Applied rules: * SimplifyIfReturnBoolRector * ReduceAlwaysFalseIfOrRector
Applied rules: * WrapEncapsedVariableInCurlyBracesRector
Applied rules: * StrictArraySearchRector * SplitDoubleAssignRector
Applied rules: * RecastingRemovalRector * CombineIfRector
Applied rules: * ForeachItemsAssignToEmptyArrayToAssignRector * SimplifyMirrorAssignRector
Applied rules: * RemoveNullPropertyInitializationRector * RemoveAlwaysElseRector
Applied rules: * RemoveAlwaysElseRector * StaticClosureRector
Applied rules: * ForRepeatedCountToOwnVariableRector * IssetOnPropertyObjectToPropertyExistsRector
Applied rules: * TernaryConditionVariableAssignmentRector * SwitchNegatedTernaryRector
Applied rules: * CompleteMissingIfElseBracketRector * CompleteDynamicPropertiesRector
Applied rules: * ChangeOrIfContinueToMultiContinueRector
Applied rules: * ShortenElseIfRector
Composer and autoload files adjusted
xmlrpc.class.php adjusted
Author
|
Hi Francisco, I see you're working on some revisions again. I've combined my latest changes into this branch for you. If you'd like, feel free to use them, or let me know how I can help. Best regards, |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
Hello,
Here is the first part of my changes and adjustments related to PHP 8.x. This includes many, many minor corrections and suggestions from SonarQube Static Code Analysis.
If you want, feel free to use them.
Best regards,
Dan Progs