get_query_args(), $this->get_query_url() ); $args = $this->get_post_args(); return wp_remote_post( esc_url_raw( $url ), $args ); } /** * An override of the method implemented by the base Tribe Handler * class to make sure the processing is done in async mode. * * This is the same code as the base WP_Background_Process class. * * @since 4.7.23 * * @param null|array $data_source An optional data source. */ public function maybe_handle( $data_source = null ) { // Don't lock up other requests while processing session_write_close(); check_ajax_referer( $this->identifier, 'nonce' ); $this->handle(); wp_die(); } /** * The task this class will perform is just setting a transient. * The transient existence will be used as a canary to detect if * background processing is supported. * * @since 4.7.23 * * @param array|null $data_source Unused. */ protected function handle( array $data_source = null ) { set_transient( self::TRANSIENT_NAME, 1, HOUR_IN_SECONDS ); } /** * Returns this handler action identifier. * * @since 4.7.23 * * @return string This handler action identifier. */ public static function action() { return 'async_process_support_test'; } }