Skip to content

Commit 78b4be1

Browse files
committed
ACF connector post_updated callback updated
1 parent d15ddf4 commit 78b4be1

File tree

1 file changed

+2
-2
lines changed

1 file changed

+2
-2
lines changed

connectors/class-connector-acf.php

+2-2
Original file line numberDiff line numberDiff line change
@@ -196,8 +196,8 @@ public function callback_post_updated( $post_id, $posts_after, $posts_before ) {
196196
return;
197197
}
198198

199-
$_new = maybe_unserialize( $posts_after->post_content ) ?? array();
200-
$_old = maybe_unserialize( $posts_before->post_content ) ?? array();
199+
$_new = ! empty( $posts_after->post_content ) ? maybe_unserialize( $posts_after->post_content ) : array();
200+
$_old = ! empty( $posts_before->post_content ) ? maybe_unserialize( $posts_before->post_content ) : array();
201201

202202
// Get updated settings.
203203
$updated_keys = $this->get_changed_keys( $_new, $_old );

0 commit comments

Comments
 (0)