Pomógłby ktoś dopisać wyświetlenie błędu w jakiekolwiek formie dla użytkownika (poza konsolą) o braku miasta żądanego z api openweathermap przy błędnym wpisie. W konsoli wyskakuje:
Failed to load resource: the server responded with a status of 404 (Not Found)
core.js:6479 ERROR HttpErrorResponse
export class CCVService {
stadt: string;
constructor(public http: HttpClient) { }
getWApi(stadt: string):Observable<ApiAntwort> {
return this.http.get<ApiAntwort>("https://api.openweathermap.org/data/2.5/forecast?q="
+ stadt
+ "&lang=pl&appid=aba3ef16bcf117xxx2238765y484777nn6");
}
}