Fix demo, use timestamp replace lastTimestamp.