diff options
| author | Syndamia <kamen.d.mladenov@protonmail.com> | 2021-02-25 14:38:12 +0200 |
|---|---|---|
| committer | Syndamia <kamen.d.mladenov@protonmail.com> | 2021-02-25 14:38:12 +0200 |
| commit | eab7b2108d91af1c905f795febf811d5cc404863 (patch) | |
| tree | 968c641667d60532c0dbc97bd13d3284f3bbcdc6 /src/app/components/feed | |
| parent | a7bf5cad6bf66f2cd7e12fc436410fafb7826b10 (diff) | |
| download | DevHive-Angular-eab7b2108d91af1c905f795febf811d5cc404863.tar DevHive-Angular-eab7b2108d91af1c905f795febf811d5cc404863.tar.gz DevHive-Angular-eab7b2108d91af1c905f795febf811d5cc404863.zip | |
Removed unnecessary variables from request subscriptions
Diffstat (limited to 'src/app/components/feed')
| -rw-r--r-- | src/app/components/feed/feed.component.ts | 9 |
1 files changed, 4 insertions, 5 deletions
diff --git a/src/app/components/feed/feed.component.ts b/src/app/components/feed/feed.component.ts index b412b3c..eaa0ef1 100644 --- a/src/app/components/feed/feed.component.ts +++ b/src/app/components/feed/feed.component.ts @@ -4,7 +4,6 @@ import { Router } from '@angular/router'; import { User } from 'src/models/identity/user'; import { UserService } from '../../services/user.service'; import { AppConstants } from 'src/app/app-constants.module'; -import { HttpErrorResponse } from '@angular/common/http'; import { FeedService } from 'src/app/services/feed.service'; import { Post } from 'src/models/post'; import { FormBuilder, FormControl, FormGroup } from '@angular/forms'; @@ -55,7 +54,7 @@ export class FeedComponent implements OnInit { Object.assign(this.user, res); this.loadFeed(); }, - (err: HttpErrorResponse) => { + () => { this.logout(); } ); @@ -67,7 +66,7 @@ export class FeedComponent implements OnInit { this.posts.push(...Object.values(result)[0]); this.finishUserLoading(); }, - (err) => { + () => { this.finishUserLoading(); } ); @@ -104,10 +103,10 @@ export class FeedComponent implements OnInit { this.dataArrived = false; this._postService.createPostWithSessionStorageRequest(postMessage, this.files).subscribe( - (result: object) => { + () => { this.goToProfile(); }, - (err: HttpErrorResponse) => { + () => { this.dataArrived = true; } ); |
