Skip to content

Commit

Permalink
Merge branch 'master' into 'master'
Browse files Browse the repository at this point in the history
[transfer-engine] Store timestamps in proper ISO-8601 UTC. Contributes to JB#34413

::toString() with time pattern can use localized numbers, which
doesn't end up proper ISO-8601 format. Also as local time
the value was ambigous after timezone change.

See merge request !1
  • Loading branch information
pvuorela committed Mar 3, 2016
2 parents b0fd8b4 + 88ab45c commit dc528c6
Showing 1 changed file with 2 additions and 4 deletions.
6 changes: 2 additions & 4 deletions src/dbmanager.cpp
Expand Up @@ -103,10 +103,8 @@ class DbManagerPrivate {

QString currentDateTime()
{
// TODO: Make sure this can handle time correctly
// Let's use ISO8601 strings
QDateTime dt = QDateTime::currentDateTime();
return dt.toString("yyyy-MM-ddThh:mm:ss");
QDateTime dt = QDateTime::currentDateTimeUtc();
return dt.toString(Qt::ISODate);
}

bool createDatabaseSchema()
Expand Down

0 comments on commit dc528c6

Please sign in to comment.