We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
2 parents f3a603f + 1b3cdfc commit cb8cd90Copy full SHA for cb8cd90
WordPress/Sniff.php
@@ -1321,7 +1321,9 @@ protected function is_assignment( $stackPtr ) {
1321
}
1322
1323
// Check if this is an array assignment, e.g., `$var['key'] = 'val';` .
1324
- if ( \T_OPEN_SQUARE_BRACKET === $this->tokens[ $next_non_empty ]['code'] ) {
+ if ( \T_OPEN_SQUARE_BRACKET === $this->tokens[ $next_non_empty ]['code']
1325
+ && isset( $this->tokens[ $next_non_empty ]['bracket_closer'] )
1326
+ ) {
1327
return $this->is_assignment( $this->tokens[ $next_non_empty ]['bracket_closer'] );
1328
1329
0 commit comments