hapi-common-log
Advanced tools
Comparing version 1.0.0 to 1.0.1
@@ -14,3 +14,3 @@ var moment = require('moment-tokens'); | ||
userid = request.id, | ||
time = moment().strftime('%d/%b/%Y:%H:%M:%S %z'), | ||
time = '[' + moment().strftime('%d/%b/%Y:%H:%M:%S %z') + ']', | ||
requestLine = '"' + [method, path, httpProtocol].join(' ') + '"', | ||
@@ -17,0 +17,0 @@ statusCode = request.response.statusCode, |
{ | ||
"name": "hapi-common-log", | ||
"version": "1.0.0", | ||
"version": "1.0.1", | ||
"description": "Parses the hapi request object to create a common log format log line", | ||
@@ -5,0 +5,0 @@ "main": "index.js", |
@@ -17,3 +17,3 @@ | ||
// output: 127.0.0.1 - 1419961634390-24985-29768 30/Dec/2014:09:47:14 -0800 "GET /static/images/npm-logo.svg HTTP/1.1" 200 - | ||
// output: 127.0.0.1 - 1419961634390-24985-29768 [30/Dec/2014:09:47:14 -0800] "GET /static/images/npm-logo.svg HTTP/1.1" 200 - | ||
@@ -20,0 +20,0 @@ ``` |
@@ -45,3 +45,3 @@ var Lab = require('lab'), | ||
expect(components[0]).to.include(expectedDate + expectedTime); | ||
expect(components[0]).to.include('[' + expectedDate + expectedTime + ']'); | ||
expect(components[1]).to.equal('GET / HTTP/1.1'); | ||
@@ -48,0 +48,0 @@ expect(components[2]).to.equal(' 200 -'); |
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
5028