From 3520869e36bb9fd568450a7283155e39c3d54dd4 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Pawe=C5=82=20Chmielowski?= Date: Mon, 7 Mar 2022 17:38:04 +0100 Subject: [PATCH] Use correct timestamp when hibernation_time is not set at all --- src/mod_muc_sql.erl | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/mod_muc_sql.erl b/src/mod_muc_sql.erl index a6a5c0908..3fed0bf2b 100644 --- a/src/mod_muc_sql.erl +++ b/src/mod_muc_sql.erl @@ -66,7 +66,7 @@ store_room(LServer, Host, Name, Opts, ChangesHints) -> end, SOpts = misc:term_to_expr(Opts2), Timestamp = case lists:keyfind(hibernation_time, 1, Opts) of - false -> <<"1900-01-01 00:00:00">>; + false -> <<"1970-01-02 00:00:00">>; {_, undefined} -> <<"1970-01-02 00:00:00">>; {_, Time} -> usec_to_sql_timestamp(Time) end,