Added support for $.timeago to accept a millisecond UNIX epoch value

#78
This commit is contained in:
Ryan McGeary 2012-05-16 11:30:02 -04:00
parent e9aff9d663
commit c3fca2db92

View file

@ -19,6 +19,8 @@
return inWords(timestamp);
} else if (typeof timestamp === "string") {
return inWords($.timeago.parse(timestamp));
} else if (typeof timestamp === "number") {
return inWords(new Date(timestamp));
} else {
return inWords($.timeago.datetime(timestamp));
}