fix uninitialized field error
This commit is contained in:
parent
2b0a58c2f2
commit
52b4aa1874
@ -48,13 +48,14 @@ function gelfAppender (layout, host, port, hostname, facility) {
|
||||
host = host || 'localhost';
|
||||
port = port || 12201;
|
||||
hostname = hostname || require('os').hostname();
|
||||
if(facility) {
|
||||
customFields['_facility'] = facility;
|
||||
}
|
||||
layout = layout || layouts.messagePassThroughLayout;
|
||||
|
||||
var defaultCustomFields = customFields || {};
|
||||
|
||||
|
||||
if(facility) {
|
||||
defaultCustomFields['_facility'] = facility;
|
||||
}
|
||||
|
||||
var client = dgram.createSocket("udp4");
|
||||
|
||||
process.on('exit', function() {
|
||||
|
Loading…
Reference in New Issue
Block a user