Title: NULL dates returned for some posts
Last modified: August 30, 2016

---

# NULL dates returned for some posts

 *  Anonymous User 92042
 * (@anonymized-92042)
 * [10 years, 10 months ago](https://wordpress.org/support/topic/null-dates-returned-for-some-posts/)
 * WP REST API 1.2.2
    WordPress 4.2.2
 * I’ve come across a problem where the WP API will sometimes return null in place
   of the post date.
 * Doing some testing, I’ve identified the problem as being related to posts with
   an incorrect _post\_date\_gmt_ of “0000-00-00 00:00:00” (how this is happening
   is a separate issue). These posts all have correct _post\_date_ values however.
 * When retrieving these posts, the plugin will return null for both _date_ and 
   _date\_gmt_.
 * Changing _post\_date\_gmt_ to “0000-00-00 00:00:01” fixes the problem.
 * Any thoughts on this would be great but I suspect this is more of a bug report
   than something I can get some help with in the short term. Suggestions are welcome
   though.
 * [https://wordpress.org/plugins/json-rest-api/](https://wordpress.org/plugins/json-rest-api/)

The topic ‘NULL dates returned for some posts’ is closed to new replies.

 * ![](https://s.w.org/plugins/geopattern-icon/json-rest-api_2e3641.svg)
 * [WP REST API (WP API)](https://wordpress.org/plugins/json-rest-api/)
 * [Frequently Asked Questions](https://wordpress.org/plugins/json-rest-api/#faq)
 * [Support Threads](https://wordpress.org/support/plugin/json-rest-api/)
 * [Active Topics](https://wordpress.org/support/plugin/json-rest-api/active/)
 * [Unresolved Topics](https://wordpress.org/support/plugin/json-rest-api/unresolved/)
 * [Reviews](https://wordpress.org/support/plugin/json-rest-api/reviews/)

 * 0 replies
 * 1 participant
 * Last reply from: Anonymous User 92042
 * Last activity: [10 years, 10 months ago](https://wordpress.org/support/topic/null-dates-returned-for-some-posts/)
 * Status: not resolved