Skip to content

Commit

Permalink
Merge pull request #286 from pantheon-systems/release_1.4.3
Browse files Browse the repository at this point in the history
Release 1.4.3
  • Loading branch information
jazzsequence authored Nov 13, 2023
2 parents 5cd922e + db98304 commit 1c7f84e
Show file tree
Hide file tree
Showing 3 changed files with 16 additions and 10 deletions.
7 changes: 5 additions & 2 deletions README.md
Original file line number Diff line number Diff line change
@@ -1,9 +1,9 @@
# WordPress Native PHP Sessions #
**Contributors:** [getpantheon](https://profiles.wordpress.org/getpantheon), [outlandish josh](https://profiles.wordpress.org/outlandish-josh), [mpvanwinkle77](https://profiles.wordpress.org/mpvanwinkle77), [danielbachhuber](https://profiles.wordpress.org/danielbachhuber), [andrew.taylor](https://profiles.wordpress.org/andrew.taylor), [jazzs3quence](https://profiles.wordpress.org/jazzs3quence), [stovak](https://profiles.wordpress.org/stovak), [jspellman](https://profiles.wordpress.org/jspellman/)
**Contributors:** [getpantheon](https://profiles.wordpress.org/getpantheon), [outlandish josh](https://profiles.wordpress.org/outlandish-josh), [mpvanwinkle77](https://profiles.wordpress.org/mpvanwinkle77), [danielbachhuber](https://profiles.wordpress.org/danielbachhuber), [andrew.taylor](https://profiles.wordpress.org/andrew.taylor), [jazzs3quence](https://profiles.wordpress.org/jazzs3quence), [stovak](https://profiles.wordpress.org/stovak), [jspellman](https://profiles.wordpress.org/jspellman/), [rwagner00](https://profiles.wordpress.org/rwagner00/)
**Tags:** comments, sessions
**Requires at least:** 4.7
**Tested up to:** 6.3
**Stable tag:** 1.4.2
**Stable tag:** 1.4.3
**Requires PHP:** 5.4
**License:** GPLv2 or later
**License URI:** http://www.gnu.org/licenses/gpl-2.0.html
Expand Down Expand Up @@ -98,6 +98,9 @@ Adds a WP-CLI command to add an index to the sessions table if one does not exis

## Changelog ##

### 1.4.3 (November 13, 2023) ###
* Fixed a PHP warning when running the `pantheon session add-index` command on a single site installation. [[#285](https://github.com/pantheon-systems/wp-native-php-sessions/pull/285)]

### 1.4.2 (November 8, 2023) ###
* Fixed an issue with the `pantheon session add-index` PHP warning. [[#276](https://github.com/pantheon-systems/wp-native-php-sessions/pull/276/files)]
* Fixed a syntax issue with the suggested WP CLI commands [[#278](https://github.com/pantheon-systems/wp-native-php-sessions/pull/278)]
Expand Down
12 changes: 6 additions & 6 deletions pantheon-sessions.php
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
<?php
/**
* Plugin Name: Native PHP Sessions for WordPress
* Version: 1.4.2
* Version: 1.4.3
* Description: Offload PHP's native sessions to your database for multi-server compatibility.
* Author: Pantheon
* Author URI: https://www.pantheon.io/
Expand All @@ -13,7 +13,7 @@

use Pantheon_Sessions\Session;

define( 'PANTHEON_SESSIONS_VERSION', '1.4.2' );
define( 'PANTHEON_SESSIONS_VERSION', '1.4.3' );

/**
* Main controller class for the plugin.
Expand Down Expand Up @@ -539,7 +539,7 @@ public function add_single_index( $prefix, $output = [], $multisite = false ) {
$query = $wpdb->prepare( 'SHOW TABLES LIKE %s', $wpdb->esc_like( $table ) );
if ( ! $wpdb->get_var( $query ) == $table ) {
$this->safe_output( __( 'This site does not have a pantheon_sessions table, and is being skipped.', 'wp-native-php-sessions' ), 'log' );
$output['no_session_table'] = $output['no_session_table'] + 1;
$output['no_session_table'] = isset( $output['no_session_table'] ) ? $output['no_session_table'] + 1 : 1;

return $output;
}
Expand All @@ -559,7 +559,7 @@ public function add_single_index( $prefix, $output = [], $multisite = false ) {
$type = 'log';
}

$output['id_column_exists'] = $output['id_column_exists'] + 1;
$output['id_column_exists'] = isset( $output['id_column_exists'] ) ? $output['id_column_exists'] + 1 : 1;
$this->safe_output( __( 'ID column already exists and does not need to be added to the table.', 'wp-native-php-sessions' ), $type );

return $output;
Expand Down Expand Up @@ -643,7 +643,7 @@ public function primary_key_finalize_single( $prefix = null, $output = [], $mult
if ( ! $multisite ) {
$type = 'error';
} else {
$output['no_old_table'] = $output['no_old_table'] + 1;
$output['no_old_table'] = isset( $output['no_old_table'] ) ? $output['no_old_table'] + 1 : 1;
$type = 'log';
}

Expand Down Expand Up @@ -688,7 +688,7 @@ public function primary_key_revert_single( $prefix = null, $output = [], $multis

if ( ! $wpdb->get_var( $query ) == $old_clone_table ) {
$this->safe_output( __( 'There is no old table to roll back to.', 'wp-native-php-sessions' ), $type );
$output['no_rollback_table'] = $output['no_rollback_table'] + 1;
$output['no_rollback_table'] = isset( $output['no_rollback_table'] ) ? $output['no_rollback_table'] + 1 : 1;

return $output;
}
Expand Down
7 changes: 5 additions & 2 deletions readme.txt
Original file line number Diff line number Diff line change
@@ -1,9 +1,9 @@
=== WordPress Native PHP Sessions ===
Contributors: getpantheon, outlandish josh, mpvanwinkle77, danielbachhuber, andrew.taylor, jazzs3quence, stovak, jspellman
Contributors: getpantheon, outlandish josh, mpvanwinkle77, danielbachhuber, andrew.taylor, jazzs3quence, stovak, jspellman, rwagner00
Tags: comments, sessions
Requires at least: 4.7
Tested up to: 6.3
Stable tag: 1.4.2
Stable tag: 1.4.3
Requires PHP: 5.4
License: GPLv2 or later
License URI: http://www.gnu.org/licenses/gpl-2.0.html
Expand Down Expand Up @@ -96,6 +96,9 @@ Adds a WP-CLI command to add an index to the sessions table if one does not exis

== Changelog ==

= 1.4.3 (November 13, 2023) =
* Fixed a PHP warning when running the `pantheon session add-index` command on a single site installation. [[#285](https://github.com/pantheon-systems/wp-native-php-sessions/pull/285)]

= 1.4.2 (November 8, 2023) =
* Fixed an issue with the `pantheon session add-index` PHP warning. [[#276](https://github.com/pantheon-systems/wp-native-php-sessions/pull/276/files)]
* Fixed a syntax issue with the suggested WP CLI commands [[#278](https://github.com/pantheon-systems/wp-native-php-sessions/pull/278)]
Expand Down

0 comments on commit 1c7f84e

Please sign in to comment.