Fix date calculation error in BuddyPress profile

This commit is contained in:
Brian Miyaji
2016-10-08 21:22:20 +11:00
parent 25e334fe89
commit 2c951dfb05

View File

@@ -158,7 +158,7 @@ class SportsPress_Birthdays {
} }
if ( 'yes' == get_option( 'sportspress_player_show_age', 'no' ) ) { if ( 'yes' == get_option( 'sportspress_player_show_age', 'no' ) ) {
$data[ __( 'Age', 'sportspress' ) ] = $this->get_age( get_the_date( 'm-d-Y' ) ); $data[ __( 'Age', 'sportspress' ) ] = $this->get_age( get_the_date( 'm-d-Y', $post_id ) );
} }
return $data; return $data;
@@ -175,7 +175,7 @@ class SportsPress_Birthdays {
} }
if ( 'yes' == get_option( 'sportspress_staff_show_age', 'no' ) ) { if ( 'yes' == get_option( 'sportspress_staff_show_age', 'no' ) ) {
$data[ __( 'Age', 'sportspress' ) ] = $this->get_age( get_the_date( 'm-d-Y' ) ); $data[ __( 'Age', 'sportspress' ) ] = $this->get_age( get_the_date( 'm-d-Y', $post_id ) );
} }
return $data; return $data;