diff options
Diffstat (limited to 'client/src/app/+about')
-rw-r--r-- | client/src/app/+about/about-follows/about-follows.component.ts | 16 | ||||
-rw-r--r-- | client/src/app/+about/about-instance/contact-admin-modal.component.ts | 8 |
2 files changed, 12 insertions, 12 deletions
diff --git a/client/src/app/+about/about-follows/about-follows.component.ts b/client/src/app/+about/about-follows/about-follows.component.ts index d335cbf45..1dcb6396c 100644 --- a/client/src/app/+about/about-follows/about-follows.component.ts +++ b/client/src/app/+about/about-follows/about-follows.component.ts | |||
@@ -91,8 +91,8 @@ export class AboutFollowsComponent implements OnInit { | |||
91 | const pagination = this.restService.componentPaginationToRestPagination(this.followersPagination) | 91 | const pagination = this.restService.componentPaginationToRestPagination(this.followersPagination) |
92 | 92 | ||
93 | this.followService.getFollowers({ pagination: pagination, sort: this.sort, state: 'accepted' }) | 93 | this.followService.getFollowers({ pagination: pagination, sort: this.sort, state: 'accepted' }) |
94 | .subscribe( | 94 | .subscribe({ |
95 | resultList => { | 95 | next: resultList => { |
96 | if (reset) this.followers = [] | 96 | if (reset) this.followers = [] |
97 | 97 | ||
98 | const newFollowers = resultList.data.map(r => r.follower.host) | 98 | const newFollowers = resultList.data.map(r => r.follower.host) |
@@ -101,16 +101,16 @@ export class AboutFollowsComponent implements OnInit { | |||
101 | this.followersPagination.totalItems = resultList.total | 101 | this.followersPagination.totalItems = resultList.total |
102 | }, | 102 | }, |
103 | 103 | ||
104 | err => this.notifier.error(err.message) | 104 | error: err => this.notifier.error(err.message) |
105 | ) | 105 | }) |
106 | } | 106 | } |
107 | 107 | ||
108 | private loadMoreFollowings (reset = false) { | 108 | private loadMoreFollowings (reset = false) { |
109 | const pagination = this.restService.componentPaginationToRestPagination(this.followingsPagination) | 109 | const pagination = this.restService.componentPaginationToRestPagination(this.followingsPagination) |
110 | 110 | ||
111 | this.followService.getFollowing({ pagination, sort: this.sort, state: 'accepted' }) | 111 | this.followService.getFollowing({ pagination, sort: this.sort, state: 'accepted' }) |
112 | .subscribe( | 112 | .subscribe({ |
113 | resultList => { | 113 | next: resultList => { |
114 | if (reset) this.followings = [] | 114 | if (reset) this.followings = [] |
115 | 115 | ||
116 | const newFollowings = resultList.data.map(r => r.following.host) | 116 | const newFollowings = resultList.data.map(r => r.following.host) |
@@ -119,8 +119,8 @@ export class AboutFollowsComponent implements OnInit { | |||
119 | this.followingsPagination.totalItems = resultList.total | 119 | this.followingsPagination.totalItems = resultList.total |
120 | }, | 120 | }, |
121 | 121 | ||
122 | err => this.notifier.error(err.message) | 122 | error: err => this.notifier.error(err.message) |
123 | ) | 123 | }) |
124 | } | 124 | } |
125 | 125 | ||
126 | } | 126 | } |
diff --git a/client/src/app/+about/about-instance/contact-admin-modal.component.ts b/client/src/app/+about/about-instance/contact-admin-modal.component.ts index 37e9feacb..cbc759881 100644 --- a/client/src/app/+about/about-instance/contact-admin-modal.component.ts +++ b/client/src/app/+about/about-instance/contact-admin-modal.component.ts | |||
@@ -83,18 +83,18 @@ export class ContactAdminModalComponent extends FormReactive implements OnInit { | |||
83 | const body = this.form.value[ 'body' ] | 83 | const body = this.form.value[ 'body' ] |
84 | 84 | ||
85 | this.instanceService.contactAdministrator(fromEmail, fromName, subject, body) | 85 | this.instanceService.contactAdministrator(fromEmail, fromName, subject, body) |
86 | .subscribe( | 86 | .subscribe({ |
87 | () => { | 87 | next: () => { |
88 | this.notifier.success($localize`Your message has been sent.`) | 88 | this.notifier.success($localize`Your message has been sent.`) |
89 | this.hide() | 89 | this.hide() |
90 | }, | 90 | }, |
91 | 91 | ||
92 | err => { | 92 | error: err => { |
93 | this.error = err.status === HttpStatusCode.FORBIDDEN_403 | 93 | this.error = err.status === HttpStatusCode.FORBIDDEN_403 |
94 | ? $localize`You already sent this form recently` | 94 | ? $localize`You already sent this form recently` |
95 | : err.message | 95 | : err.message |
96 | } | 96 | } |
97 | ) | 97 | }) |
98 | } | 98 | } |
99 | 99 | ||
100 | private prefillForm (prefill: Prefill) { | 100 | private prefillForm (prefill: Prefill) { |