Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Fix DateTimeZone setup: fall back to gmt_offset; php notice fixes #32

Merged
merged 2 commits into from
Jul 30, 2019

Conversation

adamsilverstein
Copy link

@adamsilverstein adamsilverstein commented Jul 25, 2019

Description of the Change

When timezone_string is not available (empty), fall back to gmt_offset when constructing DateTimeZone for file name.

Also includes some PHP notice fixes and some whitespace changes my editor made (removing stray spacing).

Fixes #5.

Verification Process

To test this bug, set your WordPress timezone to a "manual" offset instead of a 'named' timezone (under settings->general):

image

Once set, try exporting a print publication. Export will fail and an error will show:

image

After this fix, a zip file will download containing the export.

Checklist:

  • I have read the CONTRIBUTING document.
  • My code follows the code style of this project.
  • My change requires a change to the documentation.
  • I have updated the documentation accordingly.
  • I have added tests to cover my change.
  • All new and existing tests passed.

Applicable Issues

@adamsilverstein adamsilverstein requested a review from helen July 25, 2019 19:26
@adamsilverstein adamsilverstein mentioned this pull request Jul 25, 2019
@jeffpaul jeffpaul added this to the 1.1.0 milestone Jul 25, 2019
@jeffpaul jeffpaul added the type:bug Something isn't working. label Jul 25, 2019
@helen helen merged commit 3c803ae into develop Jul 30, 2019
@jeffpaul jeffpaul deleted the fix/DateTimeZone branch September 30, 2020 01:48
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
type:bug Something isn't working.
Projects
None yet
Development

Successfully merging this pull request may close these issues.

DateTimeZone Error
3 participants