@metrichor/epi2me-web
Advanced tools
Comparing version 4.0.4456258 to 4.0.4456738
@@ -76,3 +76,3 @@ "use strict"; | ||
if (!response.ok) { | ||
return null; | ||
return Object.assign(Object.assign({}, source), { etag: '', hasReport: false }); | ||
} | ||
@@ -83,4 +83,4 @@ const etag = response.headers.get('etag'); | ||
} | ||
return Object.assign(Object.assign({}, source), { etag }); | ||
}), operators_1.filter(ts_runtime_typecheck_1.isDefined), operators_1.filter((a) => { | ||
return Object.assign(Object.assign({}, source), { etag, hasReport: true }); | ||
}), operators_1.filter((a) => { | ||
const old = reportEtag.get(a.reportId.componentId); | ||
@@ -97,3 +97,3 @@ reportEtag.set(a.reportId.componentId, a.etag); | ||
const aggregationMap = {}; | ||
this.__telemetryReports$ = this.telemetryUpdates$().pipe(operators_1.switchMap(async (source) => { | ||
this.__telemetryReports$ = this.telemetryUpdates$().pipe(operators_1.filter((source) => { var _a; return (_a = source.hasReport) !== null && _a !== void 0 ? _a : false; }), operators_1.switchMap(async (source) => { | ||
const response = await fetch_1.fetch(source.getUrl); | ||
@@ -100,0 +100,0 @@ if (!response.ok) { |
@@ -73,3 +73,3 @@ import { fetch } from './network/fetch'; | ||
if (!response.ok) { | ||
return null; | ||
return Object.assign(Object.assign({}, source), { etag: '', hasReport: false }); | ||
} | ||
@@ -80,4 +80,4 @@ const etag = response.headers.get('etag'); | ||
} | ||
return Object.assign(Object.assign({}, source), { etag }); | ||
}), filter(isDefined), filter((a) => { | ||
return Object.assign(Object.assign({}, source), { etag, hasReport: true }); | ||
}), filter((a) => { | ||
const old = reportEtag.get(a.reportId.componentId); | ||
@@ -94,3 +94,3 @@ reportEtag.set(a.reportId.componentId, a.etag); | ||
const aggregationMap = {}; | ||
this.__telemetryReports$ = this.telemetryUpdates$().pipe(switchMap(async (source) => { | ||
this.__telemetryReports$ = this.telemetryUpdates$().pipe(filter((source) => { var _a; return (_a = source.hasReport) !== null && _a !== void 0 ? _a : false; }), switchMap(async (source) => { | ||
const response = await fetch(source.getUrl); | ||
@@ -97,0 +97,0 @@ if (!response.ok) { |
@@ -12,3 +12,3 @@ { | ||
"private": false, | ||
"version": "4.0.4456258", | ||
"version": "4.0.4456738", | ||
"main": "cjs/index-web.js", | ||
@@ -15,0 +15,0 @@ "module": "esm/index-web.js", |
Sorry, the diff of this file is too big to display
Sorry, the diff of this file is too big to display
2405689