about summary refs log tree commit diff
path: root/src/state/models/me.ts
diff options
context:
space:
mode:
authorAnsh Nanda <anshnanda10@gmail.com>2023-05-16 15:50:52 -0700
committerAnsh Nanda <anshnanda10@gmail.com>2023-05-16 15:50:52 -0700
commitf2e39d8ad24041637810327ca28ad78f9f36bf2f (patch)
tree99065f00bc87f77b7da4d62a8ccf168f6d65aa36 /src/state/models/me.ts
parentdd788550bed888259a59b01b69ac5b05893db3a5 (diff)
downloadvoidsky-f2e39d8ad24041637810327ca28ad78f9f36bf2f.tar.zst
allow for pinning saved feeds
Diffstat (limited to 'src/state/models/me.ts')
-rw-r--r--src/state/models/me.ts4
1 files changed, 4 insertions, 0 deletions
diff --git a/src/state/models/me.ts b/src/state/models/me.ts
index 314e76b9c..68c89ac9b 100644
--- a/src/state/models/me.ts
+++ b/src/state/models/me.ts
@@ -69,6 +69,7 @@ export class MeModel {
       displayName: this.displayName,
       description: this.description,
       avatar: this.avatar,
+      savedFeeds: this.savedFeeds.serialize(),
     }
   }
 
@@ -90,6 +91,9 @@ export class MeModel {
       if (hasProp(v, 'avatar') && typeof v.avatar === 'string') {
         avatar = v.avatar
       }
+      if (hasProp(v, 'savedFeeds') && isObj(v.savedFeeds)) {
+        this.savedFeeds.hydrate(v.savedFeeds)
+      }
       if (did && handle) {
         this.did = did
         this.handle = handle