diff options
| author | Syndamia <kamen.d.mladenov@protonmail.com> | 2021-02-04 14:05:36 +0200 |
|---|---|---|
| committer | Syndamia <kamen.d.mladenov@protonmail.com> | 2021-02-04 14:05:36 +0200 |
| commit | 43b3762845fc16a2bfcb50c3654180d19b1fbfb4 (patch) | |
| tree | 0f6e1085d49c0bfcf64ffdec219309a5c92e4e3d /src | |
| parent | d6196d880f98e8988c2efc68486f895d4561fab1 (diff) | |
| download | DevHive-43b3762845fc16a2bfcb50c3654180d19b1fbfb4.tar DevHive-43b3762845fc16a2bfcb50c3654180d19b1fbfb4.tar.gz DevHive-43b3762845fc16a2bfcb50c3654180d19b1fbfb4.zip | |
Improved handling of creating posts in feed
Diffstat (limited to 'src')
| -rw-r--r-- | src/DevHive.Angular/src/app/components/feed/feed.component.ts | 4 |
1 files changed, 4 insertions, 0 deletions
diff --git a/src/DevHive.Angular/src/app/components/feed/feed.component.ts b/src/DevHive.Angular/src/app/components/feed/feed.component.ts index 8e9ffbc..b412b3c 100644 --- a/src/DevHive.Angular/src/app/components/feed/feed.component.ts +++ b/src/DevHive.Angular/src/app/components/feed/feed.component.ts @@ -101,10 +101,14 @@ export class FeedComponent implements OnInit { createPost(): void { const postMessage = this.createPostFormGroup.get('newPostMessage')?.value; + this.dataArrived = false; this._postService.createPostWithSessionStorageRequest(postMessage, this.files).subscribe( (result: object) => { this.goToProfile(); + }, + (err: HttpErrorResponse) => { + this.dataArrived = true; } ); } |
