From cf85c60c1cdd1d5b80cdb8775273fcbc95a03a91 Mon Sep 17 00:00:00 2001 From: heavyweaponsgal Date: Fri, 3 May 2024 00:24:18 +0200 Subject: [PATCH] CHANGED TIMEZONE FORMATTING --- src/filters.rs | 5 ++--- 1 file changed, 2 insertions(+), 3 deletions(-) diff --git a/src/filters.rs b/src/filters.rs index 35929dc..41e1f38 100644 --- a/src/filters.rs +++ b/src/filters.rs @@ -4,10 +4,9 @@ use chrono::{DateTime, TimeZone}; use crate::post::PostMetadata; -pub fn date(date: &DateTime) -> Result { - Ok(date.to_rfc3339_opts(chrono::SecondsFormat::Secs, true)) +pub fn date(date: &DateTime) -> Result { + Ok(date.to_utc().format("%Y-%m-%d %H:%M:%S UTC").to_string()) } - pub fn duration(duration: &&Duration) -> Result { Ok(format!("{:?}", duration)) }