mirror of
https://github.com/swift-project/pilotclient.git
synced 2026-04-05 09:15:34 +08:00
Ref T308, using an optimized (faster) function for YYYYmmdd string parsing
Ref T309, found that QDateTime::fromString returns a QDateTime object with local timestamp. Using a optimized version returns UTC objects now. - The bug was found writing a unit test for Ref T308 - Slack: https://swift-project.slack.com/archives/G7GD2UP9C/p1534848725000100
This commit is contained in:
@@ -247,7 +247,7 @@ namespace BlackMisc
|
||||
|
||||
// "2/1/2014 12:00:00 AM", "5/26/2014 2:00:00 PM"
|
||||
const QString updated = attributes.namedItem("UpdatedOn").nodeValue();
|
||||
QDateTime qt = QDateTime::fromString(updated, "M/d/yyyy h:mm:ss AP");
|
||||
QDateTime qt = fromStringUtc(updated, "M/d/yyyy h:mm:ss AP");
|
||||
qint64 updatedTimestamp = qt.toMSecsSinceEpoch();
|
||||
|
||||
int rulesSize = rules.size();
|
||||
|
||||
Reference in New Issue
Block a user