about summary refs log tree commit diff
path: root/src/state/models/ui
diff options
context:
space:
mode:
Diffstat (limited to 'src/state/models/ui')
-rw-r--r--src/state/models/ui/create-account.ts4
-rw-r--r--src/state/models/ui/profile.ts12
-rw-r--r--src/state/models/ui/saved-feeds.ts2
3 files changed, 12 insertions, 6 deletions
diff --git a/src/state/models/ui/create-account.ts b/src/state/models/ui/create-account.ts
index 9f11a9b31..3bd39ba76 100644
--- a/src/state/models/ui/create-account.ts
+++ b/src/state/models/ui/create-account.ts
@@ -78,7 +78,7 @@ export class CreateAccountModel {
     } catch (err: any) {
       this.rootStore.log.warn(
         `Failed to fetch service description for ${this.serviceUrl}`,
-        err,
+        {error: err},
       )
       this.setError(
         'Unable to contact your service. Please check your Internet connection.',
@@ -127,7 +127,7 @@ export class CreateAccountModel {
         errMsg =
           'Invite code not accepted. Check that you input it correctly and try again.'
       }
-      this.rootStore.log.error('Failed to create account', e)
+      this.rootStore.log.error('Failed to create account', {error: e})
       this.setIsProcessing(false)
       this.setError(cleanError(errMsg))
       throw e
diff --git a/src/state/models/ui/profile.ts b/src/state/models/ui/profile.ts
index 8525426bf..47a99a8fc 100644
--- a/src/state/models/ui/profile.ts
+++ b/src/state/models/ui/profile.ts
@@ -223,10 +223,14 @@ export class ProfileUiModel {
     await Promise.all([
       this.profile
         .setup()
-        .catch(err => this.rootStore.log.error('Failed to fetch profile', err)),
+        .catch(err =>
+          this.rootStore.log.error('Failed to fetch profile', {error: err}),
+        ),
       this.feed
         .setup()
-        .catch(err => this.rootStore.log.error('Failed to fetch feed', err)),
+        .catch(err =>
+          this.rootStore.log.error('Failed to fetch feed', {error: err}),
+        ),
     ])
     runInAction(() => {
       this.isAuthenticatedUser =
@@ -237,7 +241,9 @@ export class ProfileUiModel {
     this.lists.source = this.profile.did
     this.lists
       .loadMore()
-      .catch(err => this.rootStore.log.error('Failed to fetch lists', err))
+      .catch(err =>
+        this.rootStore.log.error('Failed to fetch lists', {error: err}),
+      )
   }
 
   async refresh() {
diff --git a/src/state/models/ui/saved-feeds.ts b/src/state/models/ui/saved-feeds.ts
index 667bc03a3..72055abeb 100644
--- a/src/state/models/ui/saved-feeds.ts
+++ b/src/state/models/ui/saved-feeds.ts
@@ -126,7 +126,7 @@ export class SavedFeedsModel {
     this.hasLoaded = true
     this.error = cleanError(err)
     if (err) {
-      this.rootStore.log.error('Failed to fetch user feeds', err)
+      this.rootStore.log.error('Failed to fetch user feeds', {err})
     }
   }