We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
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
Since PHP 7.4 null coalesce equal operator was introduced (??=).
??=
Now instead of using null coalesce operator when assigning to a variable like:
$_GET['variable'] = $_GET['variable'] ?? 'default';
You can write
$_GET['variable'] ??= ''default';
We need to see what sniffs cover usage of this operator upstream and in the utils and if we can just use them in the WPCS ruleset.
Refs:
Related to #764
The text was updated successfully, but these errors were encountered:
All sniffs have been reviewed and fixed to support modern PHP in as far as my imagination reached.
If any more situations would be discovered which need to be taken into account, a new issue should be opened with code samples etc.
Closing this now as fixed.
Sorry, something went wrong.
No branches or pull requests
Since PHP 7.4 null coalesce equal operator was introduced (
??=
).Now instead of using null coalesce operator when assigning to a variable like:
You can write
We need to see what sniffs cover usage of this operator upstream and in the utils and if we can just use them in the WPCS ruleset.
Refs:
Related to #764
The text was updated successfully, but these errors were encountered: