| Server IP : 178.212.43.201 / Your IP : 10.100.0.33 Web Server : Apache/2.4.37 (Oracle Linux Server) OpenSSL/1.1.1k System : Linux spa0007.srv.paxillus.pl 5.4.17-2136.355.3.1.el8uek.x86_64 #3 SMP Sat May 9 17:11:55 PDT 2026 x86_64 User : apache ( 48) PHP Version : 7.4.33 Disable Function : NONE MySQL : OFF | cURL : ON | WGET : ON | Perl : ON | Python : OFF | Sudo : ON | Pkexec : ON Directory : /var/www/html/paxillus/wp-content/plugins/jetpack/sal/ |
Upload File : |
<?php // phpcs:ignore WordPress.Files.FileName.InvalidClassFileName
/**
* WPORG_Platform class that extends SAL_Platform, returning a Jetpack_Site with a $blog_id and $token
*
* @package automattic/jetpack
*/
if ( ! defined( 'ABSPATH' ) ) {
exit( 0 );
}
require_once __DIR__ . '/class.json-api-platform.php';
/**
* Base class for WPORG_Platform, which extends SAL_Platform
*/
class WPORG_Platform extends SAL_Platform {
/**
* Given a Jetpack blog ID, this function returns a Jetpack_Site instance
*
* @param int $blog_id A Jetpack blog ID.
* @return Jetpack_Site A Jetpack_Site instance including all relevant details needed to define a Jetpack site.
**/
public function get_site( $blog_id ) {
require_once __DIR__ . '/class.json-api-site-jetpack.php';
return new Jetpack_Site( $blog_id, $this );
}
}
// phpcs:disable Universal.Files.SeparateFunctionsFromOO.Mixed -- TODO: Move these functions to some other file.
/**
* Given a token instance (with blog and user id related information), this function returns a new WPORG_Platform instance
*
* @param SAL_Token $token A token instance.
* @see class.json-api-token.php
* @return WPORG_Platform A WPORG_Platform instance including all relevant details needed to define a Jetpack site, as well as a token instance.
**/
function wpcom_get_sal_platform( $token ) {
return new WPORG_Platform( $token );
}