|
@@ -6,13 +6,13 @@ import {Injectable} from "@angular/core";
|
6
|
6
|
export class UserService{
|
7
|
7
|
|
8
|
8
|
|
9
|
|
- public API = "http://localhost:8080";
|
10
|
|
- public USER_API = this.API + "/users/posts";
|
|
9
|
+ public API = "https://fast-headland-39537.herokuapp.com";
|
|
10
|
+ public USER_API = this.API + "/posts/id/";
|
11
|
11
|
|
12
|
12
|
constructor(public http: HttpClient) {
|
13
|
13
|
}
|
14
|
14
|
|
15
|
15
|
getAllPostsByUserId(id: string):Observable<any> {
|
16
|
|
- return this.http.get(this.USER_API + '/' + id);
|
|
16
|
+ return this.http.get(this.USER_API + id);
|
17
|
17
|
}
|
18
|
18
|
}
|