From 8f2fef23d3ae82c3f2fe6d6cd7679f8c4fd26e43 Mon Sep 17 00:00:00 2001 From: raduconst Date: Mon, 22 Jan 2018 08:55:49 +0200 Subject: [PATCH] Changed the way that the status on the calendar is made All I did was to replace the timesince function with the human_time_diff function from WordPress. This way, the time difference is automatically created. --- modules/story-budget/story-budget.php | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) diff --git a/modules/story-budget/story-budget.php b/modules/story-budget/story-budget.php index bdc49e9af..d67f30230 100644 --- a/modules/story-budget/story-budget.php +++ b/modules/story-budget/story-budget.php @@ -518,8 +518,7 @@ function term_column_default( $post, $column_name, $parent_term ) { return $output; break; case 'post_modified': - $modified_time_gmt = strtotime( $post->post_modified_gmt . " GMT" ); - return $this->timesince( $modified_time_gmt ); + return sprintf( esc_html__( '%s ago', 'edit-flow' ), human_time_diff( get_the_time( 'U', $post->ID ), current_time( 'timestamp' ) ) ); break; default: break;