Skip to content

Conversation

@inancgumus
Copy link

@inancgumus inancgumus commented Jul 27, 2017

mgo has an inconsistent behaviour with times indeed (see #13 and go-mgo/mgo#362).

When you fetch UTC time value from MongoDB, mgo decodes it to the local time. I fixed it with returning the time in UTC instead. So, anyone can convert it to their timezone if they want.

mgo has an inconsistent behaviour with times indeed (see this: #go-mgo#13 and this: go-mgo/mgo#362). A UTC time value which is stored as UTC in Mongo, when you fetch it, mgo decodes it to the local time. I fixed it with returning the time in UTC. So, anyone can after convert it to whatever timezone they want.
@inancgumus
Copy link
Author

@domodwyer

@domodwyer
Copy link

Hi @inancgumus, thanks for the contribution - I'm currently out of the country for a few days so sorry for the delay.

Would you mind re-targetting this PR to development and ensuring the existing tests pass? You should also include a test case for the issue at hand if possible. I've opened #20 to make the PR process clearer when I'm back in the office.

Thanks for helping!

@domodwyer
Copy link

Hi @inancgumus

Is there any progress on this?

This fork may be OK due to the changes in #13

@inancgumus
Copy link
Author

Hi @domodwyer

Sorry, I've been busy and couldn't done anything yet.

@domodwyer
Copy link

Hi @inancgumus

I'm doing a bit of cleaning and will close this PR as it's not confirmed there's an issue in this fork (#13 may cover it).

If you find the time I'll be happy to re-open!

Dom

@domodwyer domodwyer closed this Sep 4, 2017
@domodwyer domodwyer added needs info and removed bug labels Sep 4, 2017
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants