plugin updates

This commit is contained in:
Tony Volpe
2024-11-15 13:53:04 -05:00
parent 1293d604ca
commit 0238f0c4ca
2009 changed files with 163492 additions and 89543 deletions

View File

@@ -15,6 +15,9 @@ class ActionScheduler_LoggerSchema extends ActionScheduler_Abstract_Schema {
*/
protected $schema_version = 3;
/**
* Construct.
*/
public function __construct() {
$this->tables = [
self::LOG_TABLE,
@@ -28,6 +31,11 @@ class ActionScheduler_LoggerSchema extends ActionScheduler_Abstract_Schema {
add_action( 'action_scheduler_before_schema_update', array( $this, 'update_schema_3_0' ), 10, 2 );
}
/**
* Get table definition.
*
* @param string $table Table name.
*/
protected function get_table_definition( $table ) {
global $wpdb;
$table_name = $wpdb->$table;

View File

@@ -18,6 +18,9 @@ class ActionScheduler_StoreSchema extends ActionScheduler_Abstract_Schema {
*/
protected $schema_version = 7;
/**
* Construct.
*/
public function __construct() {
$this->tables = [
self::ACTIONS_TABLE,
@@ -33,10 +36,16 @@ class ActionScheduler_StoreSchema extends ActionScheduler_Abstract_Schema {
add_action( 'action_scheduler_before_schema_update', array( $this, 'update_schema_5_0' ), 10, 2 );
}
/**
* Get table definition.
*
* @param string $table Table name.
*/
protected function get_table_definition( $table ) {
global $wpdb;
$table_name = $wpdb->$table;
$charset_collate = $wpdb->get_charset_collate();
// phpcs:ignore Squiz.PHP.CommentedOutCode
$max_index_length = 191; // @see wp_get_db_schema()
$hook_status_scheduled_date_gmt_max_index_length = $max_index_length - 20 - 8; // - status, - scheduled_date_gmt
$default_date = self::DEFAULT_DATE;