From 675c42cfd5b257d6218ae010c1eb2d5ba8df541c Mon Sep 17 00:00:00 2001 From: saji <9110284+kschamplin@users.noreply.github.com> Date: Fri, 29 Sep 2023 07:53:29 +0930 Subject: [PATCH] fix marshaljson not being called --- skylab/skylab.go | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/skylab/skylab.go b/skylab/skylab.go index 12b0411..ff2904e 100644 --- a/skylab/skylab.go +++ b/skylab/skylab.go @@ -86,7 +86,7 @@ func ToCanFrame(p Packet) (id uint32, data []byte, err error) { // internal structure for partially decoding json object. // includes type RawJsonEvent struct { - Timestamp int64 `json:"ts" db:"ts"` + Timestamp int64 `json:"ts" db:"ts"` Id uint32 `json:"id"` Name string `json:"name"` Data json.RawMessage `json:"data"` @@ -99,7 +99,7 @@ type BusEvent struct { Data Packet `json:"data"` } -func (e *BusEvent) MarshalJSON() (b []byte, err error) { +func (e BusEvent) MarshalJSON() (b []byte, err error) { // create the underlying raw event j := &RawJsonEvent{ Timestamp: e.Timestamp.UnixMilli(),