Website Summary Files Commits Branches @commit @diff @stats
path: root / src / DevHive.Angular
diff options
context:
space:
mode:
Commit43b3762845fc16a2bfcb50c3654180d19b1fbfb4 (patch)
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
Files0f6e1085d49c0bfcf64ffdec219309a5c92e4e3d /src/DevHive.Angular
DevHive-43b3762845fc16a2bfcb50c3654180d19b1fbfb4.tar
DevHive-43b3762845fc16a2bfcb50c3654180d19b1fbfb4.tar.gz
DevHive-43b3762845fc16a2bfcb50c3654180d19b1fbfb4.zip
Parentd6196d880f98e8988c2efc68486f895d4561fab1 (diff)
Improved handling of creating posts in feed
1 files changed, 4 insertions, 0 deletions
-rw-r--r--src/DevHive.Angular/src/app/components/feed/feed.component.ts4
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;
}
);
}