Skip to content

Commit

Permalink
Format tweaking for posts
Browse files Browse the repository at this point in the history
  • Loading branch information
funkatron82 committed Mar 2, 2013
1 parent 108c3d7 commit caa4ee3
Showing 1 changed file with 4 additions and 7 deletions.
11 changes: 4 additions & 7 deletions inc/fields/posts.php
Expand Up @@ -33,14 +33,12 @@ static function html( $html, $meta, $field )
$field['options'] = self::get_options( $field );
switch( $field['field_type'] ) {
case 'select':
$html = RWMB_Select_Field::html( $html, $meta, $field );
return RWMB_Select_Field::html( $html, $meta, $field );
break;
case 'select_advanced':
default:
$html = RWMB_Select_Advanced_Field::html( $html, $meta, $field );
return RWMB_Select_Advanced_Field::html( $html, $meta, $field );
}

return $html;
}

/**
Expand All @@ -65,14 +63,14 @@ static function normalize_field( $field )
$field['multiple'] = false;
$field['field_name'] = 'parent_id';
}

$field['query_args'] = wp_parse_args( $field['query_args'], array(
'post_type' => $field['post_type'],
'post_status' => 'publish',
'posts_per_page'=>'-1'
) );
$field = RWMB_Select_Advanced_Field::normalize_field( $field );

return $field;
return RWMB_Select_Advanced_Field::normalize_field( $field );
}

/**
Expand Down Expand Up @@ -115,7 +113,6 @@ static function meta( $meta, $post_id, $saved, $field )
static function save( $new, $old, $post_id, $field )
{
return RWMB_Select_Field::save( $new, $old, $post_id, $field );

}

/**
Expand Down

0 comments on commit caa4ee3

Please sign in to comment.