aboutsummaryrefslogtreecommitdiffstats
path: root/src/core/utils/LocalizedUtils.cpp
diff options
context:
space:
mode:
Diffstat (limited to 'src/core/utils/LocalizedUtils.cpp')
-rw-r--r--src/core/utils/LocalizedUtils.cpp6
1 files changed, 2 insertions, 4 deletions
diff --git a/src/core/utils/LocalizedUtils.cpp b/src/core/utils/LocalizedUtils.cpp
index e1c3d859..b8c91039 100644
--- a/src/core/utils/LocalizedUtils.cpp
+++ b/src/core/utils/LocalizedUtils.cpp
@@ -32,9 +32,7 @@
namespace GpgFrontend {
-auto GetFormatedDateByTimestamp(time_t timestamp) -> std::string {
- QDateTime date;
- date.setSecsSinceEpoch(timestamp);
- return QLocale::system().toString(date).toStdString();
+auto GetFormatedDateByTimestamp(time_t timestamp) -> QString {
+ return QLocale::system().toString(QDateTime::fromSecsSinceEpoch(timestamp));
}
} // namespace GpgFrontend