1
0
mirror of https://github.com/danbee/micropub.git synced 2025-03-04 08:59:13 +00:00

Let's not assume a published time has been passed

This commit is contained in:
Daniel Barber 2019-11-11 19:20:35 -05:00
parent 3365485720
commit 4c56ac418f

View File

@ -26,7 +26,11 @@ class Post
end
def published
@_published ||= Date.parse(params["published"])
if params["published"]
DateTime.parse(params["published"])
else
DateTime.now
end
end
def categories