Fixed a bug where timestamps for latest data could be converted the wrong way.