mikelangelo-project / capstan

Capstan, a tool for packaging and running your application on OSv.
http://osv.io/capstan/
Other
19 stars 7 forks source link

Marshall empty timestamp into N/A instead of zero timestamp #55

Closed miha-plesko closed 7 years ago

miha-plesko commented 7 years ago

Currently, if we are marshalling a package with nil value for 'created' attribute, a zero timestamp gets written:

created: 0001-01-01 00:00

which is wrong. With this commit we rather marshall nil value into a N/A:

created: N/A

so that unmarshalling results into a nil date again, and not the zero one.

miha-plesko commented 7 years ago

@gberginc I'd kindly ask for a review on this one as well since https://github.com/mikelangelo-project/capstan/pull/56 depends on it.

gberginc commented 7 years ago

Instead of ? please use N/A (update commit msg as well).

My first thought when I saw the commit message with the example, was that ? implies WTF to me 😄.

Other than that, we are fine and will merge it upon receiving the update.

miha-plesko commented 7 years ago

Done. I've amended the commit as it's a very simple one.

miha-plesko commented 7 years ago

Done, I've updated the PR description. I did update the commit message, but somehow forget about PR description.

gberginc commented 7 years ago

Oh, sorry, I missed that it was only PR description. Thanks!