Skip to content
Browse files

[api] remove old timestamp function.

  • Loading branch information...
1 parent 8da081a commit 8ddbcff38f67b1a521331a8239e183c45fca5068 @chjj chjj committed
Showing with 0 additions and 24 deletions.
  1. +0 −24 lib/winston/common.js
View
24 lib/winston/common.js
@@ -182,15 +182,6 @@ exports.hash = function (str) {
};
//
-// ## Borrowed from node.js core
-// I wanted a universal lowercase header message, as opposed to the `DEBUG`
-// (i.e. all uppercase header) used only in `util.debug()`
-//
-var months = ['Jan', 'Feb', 'Mar', 'Apr',
- 'May', 'Jun', 'Jul', 'Aug',
- 'Sep', 'Oct', 'Nov', 'Dec'];
-
-//
// ### function pad (n)
// Returns a padded string if `n < 10`.
//
@@ -203,21 +194,6 @@ exports.pad = function (n) {
// Returns a timestamp string for the current time.
//
exports.timestamp = function () {
- var d = new Date();
- var time = [
- exports.pad(d.getHours()),
- exports.pad(d.getMinutes()),
- exports.pad(d.getSeconds())
- ].join(':');
-
- return [d.getDate(), months[d.getMonth()], d.getFullYear(), time].join(' ');
-};
-
-//
-// ### function timestamp ()
-// Returns a timestamp string for the current time.
-//
-exports.timestamp = function () {
return new Date().toISOString();
};

0 comments on commit 8ddbcff

Please sign in to comment.
Something went wrong with that request. Please try again.