This method is causing an error. Is there a way to fix it without changing the return type of the method? Are there any casts that can be applied to resolve the error?
private downloadIt(url: string, applicationData: any, getRequest?: boolean): Observable<{ file: Blob, url: string }> {
return this.http.get(url, applicationData, { responseType: 'blob' }).pipe(
map(file => {
const url = this.window.window.URL.createObjectURL(file);
return { file, url };
})
);