Merge pull request #1245 from majick/tag-field-wtf-logspam
Make v2 spec read logspam at least slightly actionable. Slightly.
This commit is contained in:
commit
d1d14bca13
|
@ -858,7 +858,7 @@ function unsetFavFlag(char) {
|
||||||
|
|
||||||
function readFromV2(char) {
|
function readFromV2(char) {
|
||||||
if (_.isUndefined(char.data)) {
|
if (_.isUndefined(char.data)) {
|
||||||
console.warn('Spec v2 data missing');
|
console.warn(`Char ${char['name']} has Spec v2 data missing`);
|
||||||
return char;
|
return char;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@ -893,12 +893,12 @@ function readFromV2(char) {
|
||||||
//console.debug(`Spec v2 extension data missing for field: ${charField}, using default value: ${defaultValue}`);
|
//console.debug(`Spec v2 extension data missing for field: ${charField}, using default value: ${defaultValue}`);
|
||||||
char[charField] = defaultValue;
|
char[charField] = defaultValue;
|
||||||
} else {
|
} else {
|
||||||
console.debug(`Spec v2 data missing for unknown field: ${charField}`);
|
console.debug(`Char ${char['name']} has Spec v2 data missing for unknown field: ${charField}`);
|
||||||
return;
|
return;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
if (!_.isUndefined(char[charField]) && !_.isUndefined(v2Value) && String(char[charField]) !== String(v2Value)) {
|
if (!_.isUndefined(char[charField]) && !_.isUndefined(v2Value) && String(char[charField]) !== String(v2Value)) {
|
||||||
console.debug(`Spec v2 data mismatch with Spec v1 for field: ${charField}`, char[charField], v2Value);
|
console.debug(`Char ${char['name']} has Spec v2 data mismatch with Spec v1 for field: ${charField}`, char[charField], v2Value);
|
||||||
}
|
}
|
||||||
char[charField] = v2Value;
|
char[charField] = v2Value;
|
||||||
});
|
});
|
||||||
|
|
Loading…
Reference in New Issue