Skip to content

Commit

Permalink
Merge branch 'master' into release
Browse files Browse the repository at this point in the history
  • Loading branch information
atanas-dev committed Jul 17, 2017
2 parents b15548b + cf29472 commit af0ac87
Showing 1 changed file with 6 additions and 0 deletions.
6 changes: 6 additions & 0 deletions core/Field/Sidebar_Field.php
Original file line number Diff line number Diff line change
Expand Up @@ -52,6 +52,12 @@ public function to_json( $load ) {

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

// override default value assigning behavior since sidebars are
// loaded separately and not as a part of the field options
$field_data = array_merge( $field_data, array(
'value' => $this->get_formatted_value(),
) );

if ( ! empty( $this->excluded_sidebars ) ) {
if ( ! is_array( $this->excluded_sidebars ) ) {
$this->excluded_sidebars = array( $this->excluded_sidebars );
Expand Down

0 comments on commit af0ac87

Please sign in to comment.