Skip to content
This repository
Browse code

[api] remove old timestamp function.

  • Loading branch information...
commit 8ddbcff38f67b1a521331a8239e183c45fca5068 1 parent 8da081a
Christopher Jeffrey authored May 26, 2012

Showing 1 changed file with 0 additions and 24 deletions. Show diff stats Hide diff stats

  1. 24  lib/winston/common.js
24  lib/winston/common.js
@@ -182,15 +182,6 @@ exports.hash = function (str) {
182 182
 };
183 183
 
184 184
 //
185  
-// ## Borrowed from node.js core
186  
-// I wanted a universal lowercase header message, as opposed to the `DEBUG`
187  
-// (i.e. all uppercase header) used only in `util.debug()`
188  
-//
189  
-var months = ['Jan', 'Feb', 'Mar', 'Apr',
190  
-              'May', 'Jun', 'Jul', 'Aug',
191  
-              'Sep', 'Oct', 'Nov', 'Dec'];
192  
-
193  
-//
194 185
 // ### function pad (n)
195 186
 // Returns a padded string if `n < 10`.
196 187
 //
@@ -203,21 +194,6 @@ exports.pad = function (n) {
203 194
 // Returns a timestamp string for the current time.
204 195
 //
205 196
 exports.timestamp = function () {
206  
-  var d = new Date();
207  
-  var time = [
208  
-    exports.pad(d.getHours()),
209  
-    exports.pad(d.getMinutes()),
210  
-    exports.pad(d.getSeconds())
211  
-  ].join(':');
212  
-
213  
-  return [d.getDate(), months[d.getMonth()], d.getFullYear(), time].join(' ');
214  
-};
215  
-
216  
-//
217  
-// ### function timestamp ()
218  
-// Returns a timestamp string for the current time.
219  
-//
220  
-exports.timestamp = function () {
221 197
   return new Date().toISOString();
222 198
 };
223 199
 

0 notes on commit 8ddbcff

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