From aa910260122ac5d57a8de0095668a78547ff5156 Mon Sep 17 00:00:00 2001 From: EntireTwix Date: Fri, 28 May 2021 16:20:21 -0700 Subject: [PATCH] :racehorse: improved saving for when logs are disabled --- include/user.hpp | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/include/user.hpp b/include/user.hpp index 04526f6..8e3ecd0 100644 --- a/include/user.hpp +++ b/include/user.hpp @@ -57,7 +57,10 @@ struct User Json::Value res; res["balance"] = (Json::UInt)balance; res["password"] = (Json::UInt64)password; - res["log"] = log.Serialize(); + if constexpr (max_log_size) + { + res["log"] = log.Serialize(); + } return res; } };