Skip to content

Commit af0ac87

Browse files
committed
Merge branch 'master' into release
2 parents b15548b + cf29472 commit af0ac87

File tree

1 file changed

+6
-0
lines changed

1 file changed

+6
-0
lines changed

core/Field/Sidebar_Field.php

Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -52,6 +52,12 @@ public function to_json( $load ) {
5252

5353
$field_data = parent::to_json( $load );
5454

55+
// override default value assigning behavior since sidebars are
56+
// loaded separately and not as a part of the field options
57+
$field_data = array_merge( $field_data, array(
58+
'value' => $this->get_formatted_value(),
59+
) );
60+
5561
if ( ! empty( $this->excluded_sidebars ) ) {
5662
if ( ! is_array( $this->excluded_sidebars ) ) {
5763
$this->excluded_sidebars = array( $this->excluded_sidebars );

0 commit comments

Comments
 (0)