[static-analysis] Fix static analysis level 2 errors.#679
Open
[static-analysis] Fix static analysis level 2 errors.#679
Conversation
swashata
reviewed
Dec 31, 2023
1b17dbe to
2419e91
Compare
fajardoleo
requested changes
Feb 12, 2024
bfd1c8d to
48aaba0
Compare
fajardoleo
approved these changes
Apr 16, 2024
swashata
requested changes
May 13, 2024
| ) | ||
| ); | ||
|
|
||
| $installed_addons_ids_map = array_flip( $installed_addons_ids ); |
Contributor
Author
There was a problem hiding this comment.
@swashata Yes, it is. Caught it while doing the checks. Should we push this in another PR?
includes/class-freemius.php
Outdated
| } | ||
|
|
||
| if ( ! empty( $new_user_licenses_map ) ) { | ||
| if ( count( $new_user_licenses_map ) > 0 ) { |
Contributor
There was a problem hiding this comment.
Is this something PHPStan is forcing us to do?
6ee7406 to
fe76177
Compare
e47c49a to
ae44f1c
Compare
5999f7f to
2bef074
Compare
2bef074 to
aff954f
Compare
…. 2 parameters given but 1 required.
…iables are misnamed in code that follows.
… property object.
aff954f to
522f0e1
Compare
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
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.
Proposed changes
count()You can advise on that. The goal was to maintain the checks in place and not modify functionality.