Fix applicationName typo

This commit is contained in:
ajimix
2019-03-22 12:18:56 +08:00
parent aa99167814
commit 2cb30e652d
9 changed files with 40 additions and 33 deletions

View File

@ -518,7 +518,7 @@ class RFC3164 {
* @public
* @this RFC3164
* @param {object} [options] - Options object
* @param {string} [options.applacationName='NodeJSLogger'] - Application
* @param {string} [options.applicationName='NodeJSLogger'] - Application
* @param {string} [options.hostname=os.hostname] - The name of this server
* @param {number} [options.facility=23] - Facility code to use sending this
* message
@ -561,7 +561,7 @@ class RFC3164 {
this.constructor__ = true;
options = options || {};
this.hostname = options.hostname || os.hostname();
this.applacationName = options.applacationName || '';
this.applicationName = options.applicationName || '';
this.facility = options.facility || 23;
if (options.color) {
/** @type {boolean} */
@ -840,7 +840,7 @@ class RFC3164 {
fmtMsg = '<' + pri + '>';
fmtMsg += timestamp;
fmtMsg += ' ' + this.hostname;
fmtMsg += ' ' + this.applacationName;
fmtMsg += ' ' + this.applicationName;
fmtMsg += ' ' + msg;
fmtMsg += newLine;
resolve(fmtMsg);
@ -1082,7 +1082,7 @@ class RFC5424 {
* @public
* @this RFC5424
* @param {object} [options] - Options object
* @param {string} [options.applacationName='NodeJSLogger'] - Application
* @param {string} [options.applicationName='NodeJSLogger'] - Application
* @param {string} [options.hostname=os.hostname] - The name of this server
* @param {boolean} [options.timestamp=false] - Included a Timestamp
* @param {boolean} [options.timestampUTC=false] - RFC standard is for
@ -1132,7 +1132,7 @@ class RFC5424 {
this.constructor__ = true;
options = options || {};
this.hostname = options.hostname || os.hostname();
this.applacationName = options.applacationName || '';
this.applicationName = options.applicationName || '';
if (typeof options.timestamp === 'undefined' || options.timestamp) {
/** @type {boolean} */
this.timestamp = true;
@ -1517,7 +1517,7 @@ class RFC5424 {
fmtMsg += '1'; // Version number
fmtMsg += ' ' + timestamp;
fmtMsg += ' ' + this.hostname;
fmtMsg += ' ' + this.applacationName;
fmtMsg += ' ' + this.applicationName;
fmtMsg += ' ' + pid;
fmtMsg += ' ' + id;
fmtMsg += ' ' + structuredData;