Skip to content

Commit

Permalink
line breaks
Browse files Browse the repository at this point in the history
  • Loading branch information
brendankenny committed Aug 19, 2019
1 parent 4d1b106 commit facfd35
Showing 1 changed file with 4 additions and 4 deletions.
8 changes: 4 additions & 4 deletions lighthouse-core/lib/i18n/i18n.js
Original file line number Diff line number Diff line change
Expand Up @@ -197,17 +197,17 @@ function _processParsedElements(icuMessage, argumentElements, values = {}) {
for (const {id, format} of argumentElements) {
// Throw an error if a message's value isn't provided
if (id && (id in values) === false) {
// eslint-disable-next-line max-len
throw new Error(`ICU Message "${icuMessage}" contains a value reference ("${id}") that wasn't provided`);
throw new Error(`ICU Message "${icuMessage}" contains a value reference ("${id}") ` +
`that wasn't provided`);
}

// Direct `{id}` replacement and non-numeric values need no formatting.
if (!format || format.type !== 'numberFormat') continue;

const value = values[id];
if (typeof value !== 'number') {
// eslint-disable-next-line max-len
throw new Error(`ICU Message "${icuMessage}" contains a numeric reference ("${id}") but provided value was not a number`);
throw new Error(`ICU Message "${icuMessage}" contains a numeric reference ("${id}") ` +
'but provided value was not a number');
}

// Format values for known styles.
Expand Down

0 comments on commit facfd35

Please sign in to comment.