Closed simonwheatley closed 9 years ago
The flag is set with: $this->no_meta_recursion = 'updated_post_meta';
$this->no_meta_recursion = 'updated_post_meta';
But then when the flag is lifted, the wrong property name is used: $this->updated_post_meta = false;
$this->updated_post_meta = false;
Current code as follows:
public function updated_post_meta( $meta_id, $post_id, $meta_key, $meta_value ) { // Some metadata shouldn't be synced if ( ! apply_filters( 'bbl_sync_meta_key', true, $meta_key ) ) return; if ( $this->no_meta_recursion ) return; $this->no_meta_recursion = 'updated_post_meta'; $translations = $this->get_post_translations( $post_id ); foreach ( $translations as $lang_code => & $translation ) { if ( $this->get_post_lang_code( $post_id ) == $lang_code ) continue; update_post_meta( $translation->ID, $meta_key, $meta_value ); } $this->updated_post_meta = false; }
This results in meta not being synced when it should be synced. :unamused:
Finally got that set of PRs straight.
The flag is set with:
$this->no_meta_recursion = 'updated_post_meta';
But then when the flag is lifted, the wrong property name is used:
$this->updated_post_meta = false;
Current code as follows:
This results in meta not being synced when it should be synced. :unamused: