Skip to content

Commit 657f8ce

Browse files
author
Robert Jackson
committed
Include explicit list of modules to avoid gathering telemetry for.
`fetch/ajax` throws an error when its required, no need to emit a warning for this module, since it contains no code.
1 parent 073d9c5 commit 657f8ce

File tree

1 file changed

+5
-1
lines changed

1 file changed

+5
-1
lines changed

lib/gather-telemetry.js

Lines changed: 5 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -9,13 +9,17 @@ module.exports = async function gatherTelemetry(url) {
99

1010
// Get the "viewport" of the page, as reported by the page.
1111
const telemetry = await page.evaluate(() => {
12+
const SKIPPED_MODULES = ["fetch/ajax"];
13+
1214
/* globals window, Ember */
1315
let telemetry = {};
1416

1517
const modules = Object.keys(window.require.entries);
1618

1719
for (let modulePath of modules) {
18-
let module = require(modulePath);
20+
if (SKIPPED_MODULES.includes(modulePath)) {
21+
continue;
22+
}
1923

2024
try {
2125
let module = require(modulePath);

0 commit comments

Comments
 (0)