about summary refs log tree commit diff stats
diff options
context:
space:
mode:
authorMichael Vetter <jubalh@iodoru.org>2022-04-28 19:20:38 +0200
committerMichael Vetter <jubalh@iodoru.org>2022-04-29 13:04:16 +0200
commit534ed34d739c159ce2bc3416b5fd5aa94d6a25a7 (patch)
treed6c6c3a6903c7be9b77229e5039d4540c5934d63
parent066df7f741848a2c594a5cbb05cef5af9075d5a1 (diff)
downloadprofani-tty-534ed34d739c159ce2bc3416b5fd5aa94d6a25a7.tar.gz
Use ISO8601 for chatlogs
For both 1:1 and groupchat.
-rw-r--r--src/log.c4
1 files changed, 2 insertions, 2 deletions
diff --git a/src/log.c b/src/log.c
index 1f6eaa9d..752d5b65 100644
--- a/src/log.c
+++ b/src/log.c
@@ -463,7 +463,7 @@ _chat_log_chat(const char* const login, const char* const other, const char* con
         g_date_time_ref(timestamp);
     }
 
-    gchar* date_fmt = g_date_time_format(timestamp, "%H:%M:%S");
+    gchar* date_fmt = g_date_time_format_iso8601(timestamp);
     FILE* chatlogp = fopen(dated_log->filename, "a");
     g_chmod(dated_log->filename, S_IRUSR | S_IWUSR);
     if (chatlogp) {
@@ -576,7 +576,7 @@ _groupchat_log_chat(const gchar* const login, const gchar* const room, const gch
 
     GDateTime* dt_tmp = g_date_time_new_now_local();
 
-    gchar* date_fmt = g_date_time_format(dt_tmp, "%H:%M:%S");
+    gchar* date_fmt = g_date_time_format_iso8601(dt_tmp);
 
     FILE* grpchatlogp = fopen(dated_log->filename, "a");
     g_chmod(dated_log->filename, S_IRUSR | S_IWUSR);