WordPress at Your Fingertips
function is not described

Action_Scheduler\Migration

Runner::run() public WC 1.0

Run migration batch.

{} It's a method of the class: Runner{}

No Hooks.

Return

Int. Size of batch processed.

Usage

$Runner = new Runner();
$Runner->run( $batch_size );
$batch_size(int)
Optional batch size.
Default: 10

Code of Runner::run() WC 6.1.1

public function run( $batch_size = 10 ) {
	$batch = $this->batch_fetcher->fetch( $batch_size );
	$batch_size = count( $batch );

	if ( ! $batch_size ) {
		return 0;
	}

	if ( $this->progress_bar ) {
		/* translators: %d: amount of actions */
		$this->progress_bar->set_message( sprintf( _n( 'Migrating %d action', 'Migrating %d actions', $batch_size, 'woocommerce' ), number_format_i18n( $batch_size ) ) );
		$this->progress_bar->set_count( $batch_size );
	}

	$this->migrate_actions( $batch );

	return $batch_size;
}