{"id":1638,"date":"2013-06-19T11:12:30","date_gmt":"2013-06-19T15:12:30","guid":{"rendered":"http:\/\/blogs.law.harvard.edu\/lianaleahy\/?p=1638"},"modified":"2013-06-19T11:12:30","modified_gmt":"2013-06-19T15:12:30","slug":"tip-of-the-day","status":"publish","type":"post","link":"https:\/\/archive.blogs.harvard.edu\/lianaleahy\/2013\/06\/19\/tip-of-the-day\/","title":{"rendered":"Tip of the Day"},"content":{"rendered":"<p>I&#8217;ve only ever used Date.today and Time.now to get the current date and time.  But for those of us concerned with global timezones (and who isn&#8217;t), we should really be using the <strong>.current<\/strong> method.<\/p>\n<p>Date.current is a <a href=\"http:\/\/api.rubyonrails.org\/classes\/Date.html#method-c-current\">rails core extension<\/a> that gets the current date in the set time zone.<\/p>\n<p>Awesomesauce.<\/p>\n","protected":false},"excerpt":{"rendered":"<p>I&#8217;ve only ever used Date.today and Time.now to get the current date and time. But for those of us concerned with global timezones (and who isn&#8217;t), we should really be using the .current method. Date.current is a rails core extension that gets the current date in the set time zone. Awesomesauce.<\/p>\n","protected":false},"author":1911,"featured_media":0,"comment_status":"open","ping_status":"open","sticky":false,"template":"","format":"standard","meta":{"_jetpack_memberships_contains_paid_content":false,"footnotes":""},"categories":[2850,2403],"tags":[],"class_list":["post-1638","post","type-post","status-publish","format-standard","hentry","category-professional","category-ruby-on-rails"],"jetpack_featured_media_url":"","jetpack_sharing_enabled":true,"_links":{"self":[{"href":"https:\/\/archive.blogs.harvard.edu\/lianaleahy\/wp-json\/wp\/v2\/posts\/1638","targetHints":{"allow":["GET"]}}],"collection":[{"href":"https:\/\/archive.blogs.harvard.edu\/lianaleahy\/wp-json\/wp\/v2\/posts"}],"about":[{"href":"https:\/\/archive.blogs.harvard.edu\/lianaleahy\/wp-json\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"https:\/\/archive.blogs.harvard.edu\/lianaleahy\/wp-json\/wp\/v2\/users\/1911"}],"replies":[{"embeddable":true,"href":"https:\/\/archive.blogs.harvard.edu\/lianaleahy\/wp-json\/wp\/v2\/comments?post=1638"}],"version-history":[{"count":1,"href":"https:\/\/archive.blogs.harvard.edu\/lianaleahy\/wp-json\/wp\/v2\/posts\/1638\/revisions"}],"predecessor-version":[{"id":1639,"href":"https:\/\/archive.blogs.harvard.edu\/lianaleahy\/wp-json\/wp\/v2\/posts\/1638\/revisions\/1639"}],"wp:attachment":[{"href":"https:\/\/archive.blogs.harvard.edu\/lianaleahy\/wp-json\/wp\/v2\/media?parent=1638"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/archive.blogs.harvard.edu\/lianaleahy\/wp-json\/wp\/v2\/categories?post=1638"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/archive.blogs.harvard.edu\/lianaleahy\/wp-json\/wp\/v2\/tags?post=1638"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}