Skip to content
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

Allow PHP 7 code to pass sniffs #7

Closed
stracker-phil opened this issue Nov 9, 2023 · 0 comments
Closed

Allow PHP 7 code to pass sniffs #7

stracker-phil opened this issue Nov 9, 2023 · 0 comments

Comments

@stracker-phil
Copy link

stracker-phil commented Nov 9, 2023

Currently, the ruleset.xml enforces compatibility with PHP 5.6.
However, Divi itself now requires PHP 7.4 (no recommendation, but requirement)
Also, Divi 4 makes good use of PHP 7 syntax throughout its codebase (sample: File "ChunkImagesTrait.php" uses type-hints for string, int, array)

Requested Change

Update the ruleset.xml to <config name="testVersion" value="7.0-"/> so we can use a few more modern syntax elements in our code.

Current code:

<config name="testVersion" value="5.6-"/>

Related links


Attached PR

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

5 participants