Resultat du cours n°8
This commit is contained in:
@@ -9,7 +9,7 @@ export class EmployeesService {
|
||||
constructor(private http:HttpClient) {}
|
||||
|
||||
getAllEmployees():Observable<Employee[]> {
|
||||
let host=environment.host;
|
||||
let host=Math.random()>0.2?environment.host:environment.unreachableHost;
|
||||
return this.http.get<Employee[]>(host+"/employees");
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user