Disable `DisallowShortArraySyntax` and `InternalInjectionMethod` sniffs for blocks files. (#42863)

* Disable some rules for blocks files

* Add changelog
This commit is contained in:
Thomas Roberts 2023-12-15 03:39:31 -08:00 committed by GitHub
parent d3c497f7c0
commit 865ea6ada9
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
2 changed files with 22 additions and 0 deletions

View File

@ -0,0 +1,4 @@
Significance: minor
Type: update
Add InternalInjection sniff and DisallowShortArraySyntax exceptions for blocks

View File

@ -102,4 +102,22 @@
<rule ref="Squiz.Commenting.FileComment.Missing">
<exclude-pattern>tests/php/</exclude-pattern>
</rule>
<!-- Temporary -->
<rule ref="Generic.Arrays.DisallowShortArraySyntax.Found">
<exclude-pattern>src/Blocks/</exclude-pattern>
<exclude-pattern>src/StoreApi/</exclude-pattern>
</rule>
<!-- Temporary -->
<rule ref="WooCommerce.Functions.InternalInjectionMethod.MissingFinal">
<exclude-pattern>src/Blocks/</exclude-pattern>
<exclude-pattern>src/StoreApi/</exclude-pattern>
</rule>
<!-- Temporary -->
<rule ref="WooCommerce.Functions.InternalInjectionMethod.MissingInternalTag">
<exclude-pattern>src/Blocks/</exclude-pattern>
<exclude-pattern>src/StoreApi/</exclude-pattern>
</rule>
</ruleset>