public/wordpress/wp-content/plugins/wp-courseware/includes/core/process.php
/**
	 * Task
	 *
	 * Override this method to perform any actions required on each
	 * queue item. Return the modified item for further processing
	 * in the next pass through. Or, return false to remove the
	 * item from the queue.
	 *
	 * @since 4.4.0
	 *
	 * @param mixed $callback Process Callback Function.
	 *
	 * @return mixed
	 */
Task
Override this method to perform any actions required on each
queue item. Return the modified item for further processing
in the next pass through. Or, return false to remove the
item from the queue.



@param mixed $callback Process Callback Function.

@return mixed
Task Override this method to perform any actions required on each queue item . Return the modified item for further processing in the next pass through . Or return false to remove the item from the queue . @param mixed $callback Process Callback Function . @return mixed
protected function task( $callback ) {
		wpcw_maybe_define_constant( 'WPCW_PROCESSING', $this->action );
		$result = false;
		if ( is_array( $callback ) ) {
			$callback_string = sprintf( '%s->%s', get_class( $callback[0] ), $callback[1] );
		} else {
			$callback_string = $callback;
		}
		if ( is_callable( $callback ) ) {
			$this->log( sprintf( 'Running %s callback', $callback_string ) );
			$result = (bool) call_user_func( $callback );
			if ( $result ) {
				$this->log( sprintf( '%s callback needs to run again', $callback_string ) );
			} else {
				$this->log( sprintf( 'Finished running %s callback', $callback_string ) );
			}
		} else {
			$this->log( sprintf( 'Could not find %s callback', $callback_string ) );
		}
		return $result ? $callback_string : false;
	}
protected function task ( $ callback ) { wpcw_maybe_define_constant ( 'WPCW_PROCESSING' , $ this -> action ) ; $ result = false ; if ( is_array ( $ callback ) ) { $ callback_string = sprintf ( '%s->%s' , get_class ( $ callback [ 0 ] ) , $ callback [ 1 ] ) ; } else { $ callback_string = $ callback ; } if ( is_callable ( $ callback ) ) { $ this -> log ( sprintf ( 'Running %s callback' , $ callback_string ) ) ; $ result = ( bool ) call_user_func ( $ callback ) ; if ( $ result ) { $ this -> log ( sprintf ( '%s callback needs to run again' , $ callback_string ) ) ; } else { $ this -> log ( sprintf ( 'Finished running %s callback' , $ callback_string ) ) ; } } else { $ this -> log ( sprintf ( 'Could not find %s callback' , $ callback_string ) ) ; } return $ result ? $ callback_string : false ; }
Task
 Override this method to perform any actions required on each
 queue item.
Task Override this method to perform any actions required on each queue item .