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: prevent prompt expiration with invalid expiration date #1318

Merged
merged 1 commit into from
Jun 18, 2024

Conversation

adekbadek
Copy link
Member

@adekbadek adekbadek commented Jun 18, 2024

All Submissions:

Changes proposed in this Pull Request:

Fixes a regression introduced in #1305. For some reason, some posts did get expiration_date with empty value assigned. Unfortunately, there's no way to fix these (re-publish), since we can't know which prompts were supposed to be published or not in the first place.

How to test the changes in this Pull Request:

  1. On release, assign empty value to a published prompt expiration_date meta
  2. Run wp cron event run newspack_popups_check_expiry, observe the prompt has been reverted to draft
  3. Switch to this branch, repeat, observe the prompt with invalid expiration_date is not reverted to draft

Other information:

  • Have you added an explanation of what your changes do and why you'd like us to include them?
  • Have you written new tests for your changes, as applicable?
  • Have you successfully ran tests with your changes locally?

@adekbadek adekbadek requested a review from a team as a code owner June 18, 2024 16:55
@dkoo dkoo merged commit a83cf2a into release Jun 18, 2024
9 checks passed
@dkoo dkoo deleted the hotfix/prompt-expiry branch June 18, 2024 17:13
matticbot pushed a commit that referenced this pull request Jun 18, 2024
## [2.33.1](v2.33.0...v2.33.1) (2024-06-18)

### Bug Fixes

* prevent prompt expiration with invalid expiration date ([#1318](#1318)) ([a83cf2a](a83cf2a))
@matticbot
Copy link
Contributor

🎉 This PR is included in version 2.33.1 🎉

The release is available on GitHub release

Your semantic-release bot 📦🚀

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants