getOverallErrors()

in src/core.js [524:541]


  getOverallErrors(result) {
    let overallErrors = [];

    // Collect errors from all gatherers.
    let gathererNames = this.parseGathererNames(result.gatherer);
    gathererNames = gathererNames.concat(this.overallGathererNames);
    [...new Set(gathererNames)].forEach(gathererName => {
      if (!result[gathererName]) return;

      let error = result[gathererName].error;

      // Add data source prefix to all error messages.
      if (error) {
        overallErrors.push(`[${gathererName}] ` + error);
      }
    });
    return overallErrors.filter(e => e);
  }