Make WordPress Core

Opened 14 years ago

Closed 14 years ago

#17448 closed defect (bug) (fixed)

Make sure $tz is not empty in get_gmt_from_date()

Reported by: johnjamesjacoby's profile johnjamesjacoby Owned by: nacin's profile nacin
Milestone: 3.2 Priority: normal
Severity: normal Version:
Component: Date/Time Keywords: has-patch
Focuses: Cc:

Description

It's possible that $tz might still be empty by default, which causes errors when posting new content.

See r17920 for where this was introduced.

Attachments (1)

17448.patch (828 bytes) - added by johnjamesjacoby 14 years ago.

Download all attachments as: .zip

Change History (5)

#1 @nacin
14 years ago

  • Owner set to nacin
  • Status changed from new to accepted

#2 @ryan
14 years ago

Perhaps we need to revert back and just remove the class_exists() check.

#3 @johnjamesjacoby
14 years ago

Yep, that's what needs to happen.

My patch prevents the error, but results in the post_date and post_date_gmt being the same.

#4 @ryan
14 years ago

  • Resolution set to fixed
  • Status changed from accepted to closed

In [17958]:

Revert part of [17920]. Support for empty tz must remain. Props johnjamesjacoby. fixes #17448

Note: See TracTickets for help on using tickets.