Interactivity API: fix data-wp-bind skipping valid directives after encountering an invalid one
Change `return` to `continue` in `data_wp_bind_processor` so that when an element has multiple `data-wp-bind` directives and one is invalid (empty suffix or unique ID), the invalid entry is skipped instead of causing the entire function to exit, allowing valid directives on the same element to still be processed. Props DAreRodz, ozgursar, alexodiy. Fixes #64518. Built from https://develop.svn.wordpress.org/trunk@62070 git-svn-id: http://core.svn.wordpress.org/trunk@61352 1a063a9b-81f0-0310-95a4-ce76da25c4cd
This commit is contained in:
@@ -1026,7 +1026,7 @@ final class WP_Interactivity_API {
|
||||
$entries = $this->get_directive_entries( $p, 'bind' );
|
||||
foreach ( $entries as $entry ) {
|
||||
if ( empty( $entry['suffix'] ) || null !== $entry['unique_id'] ) {
|
||||
return;
|
||||
continue;
|
||||
}
|
||||
|
||||
// Skip if the suffix is an event handler.
|
||||
|
||||
@@ -16,7 +16,7 @@
|
||||
*
|
||||
* @global string $wp_version
|
||||
*/
|
||||
$wp_version = '7.0-beta5-62069';
|
||||
$wp_version = '7.0-beta5-62070';
|
||||
|
||||
/**
|
||||
* Holds the WordPress DB revision, increments when changes are made to the WordPress DB schema.
|
||||
|
||||
Reference in New Issue
Block a user