moment.twitter icon indicating copy to clipboard operation
moment.twitter copied to clipboard

Issue with hour (over 1 hour) .fromNow() vs .twitter()

Open austb25 opened this issue 10 years ago • 1 comments

Hi there,

When I am using the .fromNow(); function in moment.js (for example, it returns "2 hours ago"), I get the correct amount of hours ago a tweet was posted, but when I use .twitter() instead, it returns the incorrect amount of hours (Instead of returning "2h" it returns "1h"). The tweets are from different feeds posted in different timezones and I convert the timestamps to UTC. Any advice on how to fix this?

Thanks!

austb25 avatar Jan 26 '15 18:01 austb25

Hey @austb25. Any chance you could create a jsfiddle to replicate the issue? If you have one of the timestamps, you should be able to create a moment instance and log the output of both methods.

hijonathan avatar Jan 28 '15 21:01 hijonathan