Mike Gerwitz

Activist for User Freedom

aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
-rw-r--r--src/system/avro/V1MessageWriter.ts3
-rw-r--r--test/system/V1MessageWriterTest.ts2
2 files changed, 3 insertions, 2 deletions
diff --git a/src/system/avro/V1MessageWriter.ts b/src/system/avro/V1MessageWriter.ts
index c6f491e..1d9a49c 100644
--- a/src/system/avro/V1MessageWriter.ts
+++ b/src/system/avro/V1MessageWriter.ts
@@ -103,11 +103,12 @@ export class V1MessageWriter implements MessageWriter
const event_id = this.DELTA_MAP[ delta.type ];
const start_date_ms = { "long": meta.startDate * 1000 };
const last_update_ms = { "long": meta.lastUpdate * 1000 };
+ const ts_ms = ts * 1000;
return {
event: {
id: event_id,
- ts: ts,
+ ts: ts_ms,
actor: 'SERVER',
step: null,
},
diff --git a/test/system/V1MessageWriterTest.ts b/test/system/V1MessageWriterTest.ts
index a0931c0..2debf9d 100644
--- a/test/system/V1MessageWriterTest.ts
+++ b/test/system/V1MessageWriterTest.ts
@@ -404,7 +404,7 @@ describe( 'system.V1MessageWriter', () =>
const expected = {
event: {
id: 'STEP_SAVE',
- ts: ts,
+ ts: ts * 1000,
actor: 'SERVER',
step: null,
},