Update armor.js
Only console.log if debug mode on
This commit is contained in:
parent
1e8bd4315b
commit
ad029f1929
|
@ -227,7 +227,7 @@ function verifyHeaders(headers) {
|
||||||
if (!/^[^:\s]+: .+$/.test(headers[i])) {
|
if (!/^[^:\s]+: .+$/.test(headers[i])) {
|
||||||
throw new Error('Improperly formatted armor header: ' + headers[i]);
|
throw new Error('Improperly formatted armor header: ' + headers[i]);
|
||||||
}
|
}
|
||||||
if (!/^(Version|Comment|MessageID|Hash|Charset): .+$/.test(headers[i])) {
|
if (config.debug && !/^(Version|Comment|MessageID|Hash|Charset): .+$/.test(headers[i])) {
|
||||||
console.log('Unknown header: ' + headers[i]);
|
console.log('Unknown header: ' + headers[i]);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
Loading…
Reference in New Issue
Block a user