aboutsummaryrefslogtreecommitdiffstats
path: root/worker/jmap/cache/session.go
diff options
context:
space:
mode:
Diffstat (limited to 'worker/jmap/cache/session.go')
-rw-r--r--worker/jmap/cache/session.go6
1 files changed, 4 insertions, 2 deletions
diff --git a/worker/jmap/cache/session.go b/worker/jmap/cache/session.go
index 7126041f..3769979a 100644
--- a/worker/jmap/cache/session.go
+++ b/worker/jmap/cache/session.go
@@ -1,6 +1,8 @@
package cache
import (
+ "encoding/json"
+
"git.sr.ht/~rockorager/go-jmap"
)
@@ -10,7 +12,7 @@ func (c *JMAPCache) GetSession() (*jmap.Session, error) {
return nil, err
}
s := new(jmap.Session)
- err = unmarshal(buf, s)
+ err = json.Unmarshal(buf, s)
if err != nil {
return nil, err
}
@@ -18,7 +20,7 @@ func (c *JMAPCache) GetSession() (*jmap.Session, error) {
}
func (c *JMAPCache) PutSession(s *jmap.Session) error {
- buf, err := marshal(s)
+ buf, err := json.Marshal(s)
if err != nil {
return err
}