added check for undefined

This commit is contained in:
7h3Rabbit 2025-02-22 21:08:02 +01:00
parent b6eb3a951c
commit 9b42ab7662
1 changed files with 2 additions and 0 deletions

View File

@ -82,6 +82,8 @@ export default class PageXrayPlugin extends SitespeedioPlugin {
firstParty: this.options.firstParty ?? undefined
};
const pageSummary = pagexray.convert(message.data, config);
if (!pageSummary) break;
//check and print any http server error > 399
for (let summary of pageSummary) {
if (Object.keys(summary.responseCodes).some(code => code > 399)) {