diff options
author | Chocobozzz <me@florianbigard.com> | 2021-08-17 11:27:47 +0200 |
---|---|---|
committer | Chocobozzz <me@florianbigard.com> | 2021-08-17 14:01:45 +0200 |
commit | 1378c0d343028f3d40d7d795422684ab9e6a1599 (patch) | |
tree | 08062b84a38a7e2dfe0aa674e7ca8e1b7321044e /client/src/app/shared/shared-main | |
parent | c186a67f90203af6bfa434f026efdc99193bcd65 (diff) | |
download | PeerTube-1378c0d343028f3d40d7d795422684ab9e6a1599.tar.gz PeerTube-1378c0d343028f3d40d7d795422684ab9e6a1599.tar.zst PeerTube-1378c0d343028f3d40d7d795422684ab9e6a1599.zip |
Fix client lint
Diffstat (limited to 'client/src/app/shared/shared-main')
-rw-r--r-- | client/src/app/shared/shared-main/auth/auth-interceptor.service.ts | 2 | ||||
-rw-r--r-- | client/src/app/shared/shared-main/users/user-notifications.component.ts | 24 |
2 files changed, 13 insertions, 13 deletions
diff --git a/client/src/app/shared/shared-main/auth/auth-interceptor.service.ts b/client/src/app/shared/shared-main/auth/auth-interceptor.service.ts index a75c8a25c..51248c7b2 100644 --- a/client/src/app/shared/shared-main/auth/auth-interceptor.service.ts +++ b/client/src/app/shared/shared-main/auth/auth-interceptor.service.ts | |||
@@ -36,7 +36,7 @@ export class AuthInterceptor implements HttpInterceptor { | |||
36 | return this.handleNotAuthenticated(err) | 36 | return this.handleNotAuthenticated(err) |
37 | } | 37 | } |
38 | 38 | ||
39 | return observableThrowError(err) | 39 | return observableThrowError(() => err) |
40 | }) | 40 | }) |
41 | ) | 41 | ) |
42 | } | 42 | } |
diff --git a/client/src/app/shared/shared-main/users/user-notifications.component.ts b/client/src/app/shared/shared-main/users/user-notifications.component.ts index 96b141543..50005b855 100644 --- a/client/src/app/shared/shared-main/users/user-notifications.component.ts +++ b/client/src/app/shared/shared-main/users/user-notifications.component.ts | |||
@@ -56,8 +56,8 @@ export class UserNotificationsComponent implements OnInit { | |||
56 | } | 56 | } |
57 | 57 | ||
58 | this.userNotificationService.listMyNotifications(options) | 58 | this.userNotificationService.listMyNotifications(options) |
59 | .subscribe( | 59 | .subscribe({ |
60 | result => { | 60 | next: result => { |
61 | this.notifications = reset ? result.data : this.notifications.concat(result.data) | 61 | this.notifications = reset ? result.data : this.notifications.concat(result.data) |
62 | this.componentPagination.totalItems = result.total | 62 | this.componentPagination.totalItems = result.total |
63 | 63 | ||
@@ -66,8 +66,8 @@ export class UserNotificationsComponent implements OnInit { | |||
66 | this.onDataSubject.next(result.data) | 66 | this.onDataSubject.next(result.data) |
67 | }, | 67 | }, |
68 | 68 | ||
69 | err => this.notifier.error(err.message) | 69 | error: err => this.notifier.error(err.message) |
70 | ) | 70 | }) |
71 | } | 71 | } |
72 | 72 | ||
73 | onNearOfBottom () { | 73 | onNearOfBottom () { |
@@ -84,26 +84,26 @@ export class UserNotificationsComponent implements OnInit { | |||
84 | if (notification.read) return | 84 | if (notification.read) return |
85 | 85 | ||
86 | this.userNotificationService.markAsRead(notification) | 86 | this.userNotificationService.markAsRead(notification) |
87 | .subscribe( | 87 | .subscribe({ |
88 | () => { | 88 | next: () => { |
89 | notification.read = true | 89 | notification.read = true |
90 | }, | 90 | }, |
91 | 91 | ||
92 | err => this.notifier.error(err.message) | 92 | error: err => this.notifier.error(err.message) |
93 | ) | 93 | }) |
94 | } | 94 | } |
95 | 95 | ||
96 | markAllAsRead () { | 96 | markAllAsRead () { |
97 | this.userNotificationService.markAllAsRead() | 97 | this.userNotificationService.markAllAsRead() |
98 | .subscribe( | 98 | .subscribe({ |
99 | () => { | 99 | next: () => { |
100 | for (const notification of this.notifications) { | 100 | for (const notification of this.notifications) { |
101 | notification.read = true | 101 | notification.read = true |
102 | } | 102 | } |
103 | }, | 103 | }, |
104 | 104 | ||
105 | err => this.notifier.error(err.message) | 105 | error: err => this.notifier.error(err.message) |
106 | ) | 106 | }) |
107 | } | 107 | } |
108 | 108 | ||
109 | changeSortColumn (column: string) { | 109 | changeSortColumn (column: string) { |