Skip to content

Commit

Permalink
Merge pull request #198 from awesomemotive/release/4.7.3.1
Browse files Browse the repository at this point in the history
`release/4.7.3.1`
  • Loading branch information
spencerfinnell authored Mar 31, 2023
2 parents 8266361 + 9f546ac commit 9d7ca3f
Show file tree
Hide file tree
Showing 4 changed files with 28 additions and 26 deletions.
2 changes: 1 addition & 1 deletion package.json
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@
"name": "wp-simple-pay-lite",
"title": "WP Simple Pay Lite for Stripe",
"description": "Add high conversion Stripe Checkout forms to your WordPress site and start accepting payments in minutes. **Lite Version**",
"version": "4.7.3",
"version": "4.7.31",
"license": "GPL-2.0-or-later",
"homepage": "https://wpsimplepay.com/",
"repository": {
Expand Down
13 changes: 4 additions & 9 deletions readme.txt
Original file line number Diff line number Diff line change
Expand Up @@ -284,6 +284,10 @@ No. WP Simple Pay is a standalone Stripe payments plugin and does not integrate

== Changelog ==

= Stripe Payment Forms v4.7.3.1 - March 31, 2023 =

* Fix: Check that `jddayofweek()` is available before use.

= Stripe Payment Forms v4.7.3 - March 30, 2023 =

* New: Add a "Summary Report" email to stay up to date with payment form performance.
Expand All @@ -300,12 +304,3 @@ No. WP Simple Pay is a standalone Stripe payments plugin and does not integrate
* Dev: Update to Stripe API version 2022-11-15.
* Dev: Update the Stripe API PHP library to 10.6.0.

= Stripe Payment Forms v4.6.7 - January 24, 2023 =

* New "Activity & Reports" - see an overview of latest activity and filterable reports.
* New: Warn users before trashing or deleting a payment form.
* Fix: Ensure WordPress <= 5.5 compatibility.
* Fix: Avoid JavaScript errors on pages where elements do not exist.
* Dev: Update known plugin conflict list.
* Dev: Update documentation URLs.

35 changes: 21 additions & 14 deletions src/Emails/SummaryReportEmailScheduler.php
Original file line number Diff line number Diff line change
Expand Up @@ -114,27 +114,34 @@ public function schedule_email() {

$has_next = $this->scheduler->has_next( $hook );

if ( $has_next ) {
return;
}

// If there isn't a scheduled event for the current interval then the
// setting has changed. We need to cancel the existing event and schedule
// a new one.
if ( ! $has_next ) {
foreach ( $unused_intervals as $unused_interval ) {
$unused_hook = sprintf(
'simpay_send_email_%s_%s',
$this->email->get_id(),
$unused_interval
);

$this->scheduler->unschedule_all( $unused_hook );
}
foreach ( $unused_intervals as $unused_interval ) {
$unused_hook = sprintf(
'simpay_send_email_%s_%s',
$this->email->get_id(),
$unused_interval
);

$this->scheduler->unschedule_all( $unused_hook );
}

/** @var string $start_of_week_no */
$start_of_week_no = get_option( 'start_of_week', '0' );
$start_of_week_no = (int) $start_of_week_no;
if ( function_exists( 'jddayofweek' ) ) {
/** @var string $start_of_week_no */
$start_of_week_no = get_option( 'start_of_week', '0' );
$start_of_week_no = (int) $start_of_week_no;

$start_of_week = jddayofweek( $start_of_week_no - 1, 1 );
} else {
$start_of_week = 'monday';
}

/** @var string $start_of_week */
$start_of_week = jddayofweek( $start_of_week_no - 1, 1 );

switch ( $send_interval ) {
case 'monthly':
Expand Down
4 changes: 2 additions & 2 deletions stripe-checkout.php
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,7 @@
* Description: Add high conversion Stripe payment forms to your WordPress site in minutes.
* Author: WP Simple Pay
* Author URI: https://wpsimplepay.com
* Version: 4.7.3
* Version: 4.7.3.1
* Text Domain: stripe
* Domain Path: /languages
*/
Expand Down Expand Up @@ -54,7 +54,7 @@
//
// Lite/Pro-specific.
//
define( 'SIMPLE_PAY_VERSION', '4.7.3' );
define( 'SIMPLE_PAY_VERSION', '4.7.3.1' );

if ( ! defined( 'SIMPLE_PAY_PLUGIN_NAME' ) ) {
define( 'SIMPLE_PAY_PLUGIN_NAME', 'WP Simple Pay Lite' );
Expand Down

0 comments on commit 9d7ca3f

Please sign in to comment.