From 2644ab016a3c0e400ea4acdcfd02bdc9a908b917 Mon Sep 17 00:00:00 2001 From: Andrew Schaaf Date: Tue, 7 Jun 2011 15:11:57 -0400 Subject: [PATCH] %s: seconds, not ms (closes #6) --- lib/index.js | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/lib/index.js b/lib/index.js index 614b8f2..1772807 100644 --- a/lib/index.js +++ b/lib/index.js @@ -100,7 +100,7 @@ case 'R': return strftime(locale.formats.R || '%H:%M', d, locale); case 'r': return strftime(locale.formats.r || '%I:%M:%S %p', d, locale); case 'S': return pad(d.getSeconds()); - case 's': return d.getTime(); + case 's': return Math.floor(d.getTime() / 1000); case 'T': return strftime(locale.formats.T || '%H:%M:%S', d, locale); case 't': return '\t'; case 'u':