Make WordPress Core

Changeset 52284


Ignore:
Timestamp:
11/30/2021 05:10:19 PM (3 years ago)
Author:
SergeyBiryukov
Message:

Upgrade/Install: Check that WordPress is installed before scheduling cleanup of the temp-backup directory.

Trying to schedule cron jobs before WordPress is installed results in DB errors, which is suboptimal.

This addresses a Table 'wp_options' doesn't exist error when running the installation with WP_DEBUG enabled.

Follow-up to [51815], [51898], [51899], [51902], [52192].

Props dlh, pbiron.
See #51857.

File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/src/wp-admin/includes/class-wp-upgrader.php

    r52204 r52284  
    142142        $this->skin->set_upgrader( $this );
    143143        $this->generic_strings();
    144         $this->schedule_temp_backup_cleanup();
     144
     145        if ( ! wp_installing() ) {
     146            $this->schedule_temp_backup_cleanup();
     147        }
    145148    }
    146149
Note: See TracChangeset for help on using the changeset viewer.