• Skip to primary navigation
  • Skip to main content
  • Skip to primary sidebar
  • Skip to footer
Jetpack a2z

Jetpack a2z

Jetpack a2z

  • Home
  • Plugins
  • Blocks
  • Shortcodes
  • APIs
  • Classes
  • Files
  • Hooks
  • Sitemap
  • Blog
Home / APIs / Actions::add_sender_shutdown() – Prepares sync to send actions on shutdown for the current request.

You appear to be a bot. Output may be restricted

Description

Prepares sync to send actions on shutdown for the current request.

Usage

Actions::add_sender_shutdown();

Parameters

Returns

void

Source

File name: jetpack/vendor/automattic/jetpack-sync/src/Actions.php


Lines:

1 to 24 of 24
  public static function add_sender_shutdown() {
    
/**
 * Fires on every request before default loading sync sender code.
 * Return false to not load sync sender code that serializes pending
 * data and sends it to WPCOM for processing.
 *
 * By default this returns true for cron jobs, POST requests, admin requests, or requests
 * by users who can manage_options.
 *
 * @since 4.2.0
 *
 * @param bool should we load sync sender code for this request
 */
    if ( apply_filters(
      'jetpack_sync_sender_should_load',
      self::should_initialize_sender()
    ) ) {
      self::initialize_sender();
      add_action( 'shutdown', array( self::$sender, 'do_sync' ) );
      add_action( 'shutdown', array( self::$sender, 'do_full_sync' ) );
    }
  }
 

 View on GitHub View on Trac

Share this:

  • Click to share on Twitter (Opens in new window)
  • Click to share on Facebook (Opens in new window)
  • Click to share on LinkedIn (Opens in new window)
  • Click to share on Pinterest (Opens in new window)

Related

Published: 27 November 2019 | Last updated: 27 November 2019

Primary Sidebar

Information

Function name: Actions::add_sender_shutdown
Class ref: Actions
Plugin ref: Jetpack
Version: 7.9.1
Sourcefile: vendor/automattic/jetpack-sync/src/Actions.php
File ref: vendor/automattic/jetpack-sync/src/Actions.php
Deprecated?: No
API Letters: A,S

Footer

Jetpack a2z Jetpack a2z
Jetpack a2z
WordPress 5.3
WordPress a2z
WordPress core a2z
Genesis Theme Framework a2z
Jetpack a2z
WordPress develop tests
Easy Digital Downloads a2z
WooCommerce a2z
Yoast SEO a2z
WordPress Blocks

Site:  jetpack.wp-a2z.org
© Copyright Jetpack a2z 2014-2019. All rights reserved.


Website designed and developed by Herb Miller
Proudly powered by WordPress and oik plugins

  • Home
  • Blog
  • Sitemap
  • Sites