Skip to content

Commit

Permalink
Check bw_theme_field_date exists Fixes #182
Browse files Browse the repository at this point in the history
  • Loading branch information
bobbingwide committed Aug 16, 2021
1 parent b14a3ea commit d2598fa
Showing 1 changed file with 7 additions and 3 deletions.
10 changes: 7 additions & 3 deletions libs/bw_fields.php
Expand Up @@ -217,7 +217,7 @@ function bw_theme_field__post_title( $key, $value, $field ) {
* @param $field
*/
function bw_theme_field__post_date( $key, $value, $field ) {
bw_theme_field__date( $key, $value, $field );
bw_theme_field__date($key, $value, $field);
}

/**
Expand All @@ -229,7 +229,7 @@ function bw_theme_field__post_date( $key, $value, $field ) {
* @param $field
*/
function bw_theme_field__post_modified( $key, $value, $field ) {
bw_theme_field__date( $key, $value, $field );
bw_theme_field__date($key, $value, $field);
}

/**
Expand All @@ -242,7 +242,11 @@ function bw_theme_field__post_modified( $key, $value, $field ) {
*/
function bw_theme_field__date( $key, $value, $field ) {
span( $key );
bw_theme_field_date( $key, $value, $field );
if ( function_exists( 'bw_theme_field_date') ) {
bw_theme_field_date( $key, $value, $field );
} else {
_bw_theme_field_default( $key, $value, $field );
}
epan();
}

Expand Down

0 comments on commit d2598fa

Please sign in to comment.