about summary refs log tree commit diff
path: root/src/state/models/feeds
diff options
context:
space:
mode:
authorEric Bailey <git@esb.lol>2023-11-04 12:42:27 -0500
committerEric Bailey <git@esb.lol>2023-11-04 12:42:27 -0500
commitdf0dcf32f99631c52b039c7f1934481924d37465 (patch)
treef190c6e24744b01be9a98c4a9e25282bf050a178 /src/state/models/feeds
parent5fd41ad5a2734e1721a82134efe5487e818b790d (diff)
downloadvoidsky-df0dcf32f99631c52b039c7f1934481924d37465.tar.zst
Fix immediate TS errors
Diffstat (limited to 'src/state/models/feeds')
-rw-r--r--src/state/models/feeds/notifications.ts2
-rw-r--r--src/state/models/feeds/post.ts15
2 files changed, 8 insertions, 9 deletions
diff --git a/src/state/models/feeds/notifications.ts b/src/state/models/feeds/notifications.ts
index 34f5d4add..3f18c18d7 100644
--- a/src/state/models/feeds/notifications.ts
+++ b/src/state/models/feeds/notifications.ts
@@ -220,7 +220,7 @@ export class NotificationsFeedItemModel {
     }
     this.rootStore.log.warn(
       'app.bsky.notifications.list served an unsupported record type',
-      v,
+      {record: v},
     )
   }
 
diff --git a/src/state/models/feeds/post.ts b/src/state/models/feeds/post.ts
index d46cced75..3def5dce3 100644
--- a/src/state/models/feeds/post.ts
+++ b/src/state/models/feeds/post.ts
@@ -42,10 +42,9 @@ export class PostsFeedItemModel {
       } else {
         this.postRecord = undefined
         this.richText = undefined
-        rootStore.log.warn(
-          'Received an invalid app.bsky.feed.post record',
-          valid.error,
-        )
+        rootStore.log.warn('Received an invalid app.bsky.feed.post record', {
+          error: valid.error,
+        })
       }
     } else {
       this.postRecord = undefined
@@ -133,7 +132,7 @@ export class PostsFeedItemModel {
         track('Post:Like')
       }
     } catch (error) {
-      this.rootStore.log.error('Failed to toggle like', error)
+      this.rootStore.log.error('Failed to toggle like', {error})
     }
   }
 
@@ -168,7 +167,7 @@ export class PostsFeedItemModel {
         track('Post:Repost')
       }
     } catch (error) {
-      this.rootStore.log.error('Failed to toggle repost', error)
+      this.rootStore.log.error('Failed to toggle repost', {error})
     }
   }
 
@@ -182,7 +181,7 @@ export class PostsFeedItemModel {
         track('Post:ThreadMute')
       }
     } catch (error) {
-      this.rootStore.log.error('Failed to toggle thread mute', error)
+      this.rootStore.log.error('Failed to toggle thread mute', {error})
     }
   }
 
@@ -191,7 +190,7 @@ export class PostsFeedItemModel {
       await this.rootStore.agent.deletePost(this.post.uri)
       this.rootStore.emitPostDeleted(this.post.uri)
     } catch (error) {
-      this.rootStore.log.error('Failed to delete post', error)
+      this.rootStore.log.error('Failed to delete post', {error})
     } finally {
       track('Post:Delete')
     }