Merge pull request #20821 from woocommerce/fix/20718

Pass an instance of the background updater to the db update callbacks
This commit is contained in:
Gerhard Potgieter 2018-07-18 14:51:12 +02:00 committed by GitHub
commit ea2b3f9d7a
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
1 changed files with 1 additions and 1 deletions

View File

@ -106,7 +106,7 @@ class WC_Background_Updater extends WC_Background_Process {
if ( is_callable( $callback ) ) {
$logger->info( sprintf( 'Running %s callback', $callback ), array( 'source' => 'wc_db_updates' ) );
$result = (bool) call_user_func( $callback );
$result = (bool) call_user_func( $callback, $this );
if ( $result ) {
$logger->info( sprintf( '%s callback needs to run again', $callback ), array( 'source' => 'wc_db_updates' ) );